Full-Stack Web App
intermediateCloudFront + S3 frontend, API Gateway + Lambda backend, Cognito auth, and Aurora Serverless v2 PostgreSQL. Production-ready full-stack pattern with all wiring included.
Quick Start
Via CLI (recommended)
npx cdk-starter create Then select "Full-Stack Web App" from the prompt
Or scaffold directly
npx cdk-starter create --starter full-stack-webapp README
Full-Stack Web App
Complete full-stack pattern: CloudFront + S3 frontend, API Gateway + Lambda backend, Cognito auth, and Aurora Serverless v2 PostgreSQL. All components are wired together in a single stack.
Frontend
Build your frontend and put the output in frontend/dist/:
cd frontend && npm run build
Backend
Edit src/api.ts to add your Lambda handler logic.
Database
The Aurora cluster endpoint and credentials ARN are available as stack outputs.
Prerequisites
- Node.js ≥ 20
- AWS CLI configured (
aws configure) - CDK bootstrapped (
npx cdk bootstrap)
Deploy
npm install
npx cdk diff
npx cdk deploy
Tear down
npx cdk destroy