cicd-examples
CI/CD Comparison
Each stack uses GitHub Actions to:
- Install dependencies
- Run tests
- Build artifacts
- Deploy to AWS (Lambda or S3/CloudFront)
Backend CI (Node / TypeScript)
Stack 1 & 3 backend workflow (simplified):
jobs:
test:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./backend
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '18'
- run: npm ci
- run: npm test
- run: npm run build
Backend CI (Python / FastAPI)
Stack 2 & 4 backend workflow (simplified):
jobs:
test:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./backend
services:
postgres:
image: postgres:15
env:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: todos_test
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.11'
- run: pip install -r requirements.txt
- run: alembic upgrade head
- run: pytest
Frontend CI patterns are similar: install → test/lint → build → deploy to S3 + CloudFront.