Appearance
Quick Reference Guide
Common tasks and where to find what you need.
Quick Links
- Environment URLs & Costs - All environment URLs and infrastructure costs
- Technology Stack - Complete list of technologies and versions
- CI/CD Pipeline - How deployments work
Adding Environment Variables
Where it fits: Environment variables flow from env.deploy.yml → Scripts → GitHub Actions → Everywhere
Steps:
Add to
infra/deploy/env.deploy.yml:yamlDEV: server: MY_NEW_VAR: 'value' # Plain value MY_SECRET: 'from_secrets' # Auto-generates DEV_SERVER_MY_SECRETTest locally:
bashcd infra/deploy # See what secrets are needed node scripts/generate-env-files.js DEV --list-secrets # Test env generation node scripts/generate-env-files.js DEV --server --dry-runAdd secret to GitHub if needed
Key Scripts:
generate-env-files.js- Creates .env files from env.deploy.ymlextract-config.js- Extracts terraform vars, secrets list, documentation
Learn more: CI/CD Pipeline
Creating a New API Endpoint
Where it fits: Routes → Controller → Service → Database
Steps:
- Create controller in
apps/server/app/controllers/YourController.ts - Add route in
apps/server/start/routes.ts - Add validation in
apps/server/app/validators/ - Test with:
curl http://localhost:3333/api/your-endpoint
Conventions:
- RESTful naming:
GET /events,POST /events,GET /events/:id - Controllers handle HTTP logic only
- Business logic goes in services
Learn more: Controllers & Routing
Adding a Frontend Component
Where it fits: Component → Page → Route
React App (apps/webapp/):
- Create component in
src/components/ - Use in pages under
src/routes/ - Add to route if new page
Conventions:
- Use TypeScript interfaces for props
- Keep components pure when possible
- Co-locate styles with components
Learn more: Component Library
Database Changes
Where it fits: Migration → Model → Controller
Steps:
Create migration:
bashcd apps/server node ace make:migration create_events_tableRun migration:
bashnpm run migration:runCreate/update model in
apps/server/app/models/
Conventions:
- Plural table names:
users,events - Singular model names:
User,Event - Always include timestamps
Learn more: Database Setup
Deploying Changes
Where it fits: Your code → GitHub → Actions → Cloud
Automatic deployment on push to:
develop→ Development environmentqa→ QA environmentmain→ Production (requires approval)
Manual deployment:
bash
# Never needed for normal work - GitHub Actions handles it
# But if you must: see deployment docsLearn more: CI/CD Pipeline
Debugging Issues
Backend Debugging
Check logs:
bash
# Local development
npm run dev:server
# Look at console output
# Production
# Check GitHub Actions logs
# SSH to server: docker compose logs serverCommon issues:
- Database connection: Check
DB_HOSTin.env - Port conflicts: Change
PORTin.env
Frontend Debugging
Browser DevTools:
- Network tab: Check API calls
- Console: JavaScript errors
- React DevTools: Component state
Common issues:
- CORS errors: Check
VITE_API_URL - Build errors: Clear
.turbocache
Learn more: Troubleshooting
Working with Docker
Local services (PostgreSQL, Redis, Caddy):
bash
cd infra/local_dev
# Start
docker compose up -d
# Stop
docker compose down
# Reset (warning: deletes data)
docker compose down -vService locations:
- PostgreSQL:
localhost:5433 - Redis:
localhost:6379 - Caddy:
https://*.jubiloop.localhost
Learn more: Local Infrastructure
Git Workflow
Creating branches:
bash
# Traditional approach:
git checkout -b feature/sc-123-description
# Using git worktrees (recommended for parallel work):
./scripts/worktree.sh feature/sc-123-descriptionDaily workflow:
bash
# Start of day
git checkout develop
git pull origin develop
git checkout -b feature/sc-123-new-feature
# Before pushing
git add .
git commit -m "[sc-123] add new feature"
git push origin feature/sc-123-new-featureWorking on multiple features (with worktrees):
bash
# Create worktrees for parallel development
./scripts/worktree.sh feature/sc-100-api-feature
./scripts/worktree.sh feature/sc-101-ui-feature
# Switch between them
./scripts/worktree-switch.sh feature/sc-100-api-feature
# List all worktrees
./scripts/worktree-list.sh
# Clean up when done
./scripts/worktree-remove.sh feature/sc-100-api-featureLearn more:
Code Organization
apps/
├── server/ # Backend API (AdonisJS)
│ ├── app/ # Controllers, models, validators
│ ├── config/ # Configuration files
│ └── start/ # Routes and bootstrapping
├── webapp/ # Web application (React)
│ ├── src/ # Components, routes, stores
│ └── public/ # Static assets
└── marketing/ # Marketing site (Next.js)
├── src/ # Pages and components
└── public/ # Static assetsLearn more: Monorepo Structure
Getting Help
- Check documentation - You're here!
- Search codebase - Often the best examples
- Check Shortcut - Similar tasks might have notes
- Ask your teammate - When stuck
Most Used Commands
bash
# Development
npm run dev # Start everything
npm run dev:server # Backend only
npm run dev:webapp # Frontend only
# Database
npm run migration:run # Run migrations
npm run migration:rollback # Rollback
npm run db:seed # Seed data
# Code quality
npm run lint # Check code style
npm run format # Auto-fix formatting
npm run test # Run tests
# Build
npm run build # Build everything
npm run build:server # Backend only
npm run build:webapp # Frontend only
# Git Worktrees (for parallel development)
./scripts/worktree.sh feature/name # Create worktree
./scripts/worktree-list.sh # List all worktrees
./scripts/worktree-switch.sh feature # Switch to worktree
./scripts/worktree-remove.sh feature # Remove worktreeKey Files to Know
env.deploy.yml- All environment configurationturbo.json- Monorepo task configuration.github/workflows/- CI/CD pipelinesdocker-compose.yml- Local servicesapps/server/start/routes.ts- API routesapps/webapp/src/routes/- Frontend routes