Scripts that may help during development:
Looking for automation details? See scripts/README.md for bundle options and deeper guidance.
The unified CDK orchestration script handles all CDKTF operations:
# Show current state
node scripts/cdk.mjs status
# Deploy infrastructure stacks (api-stack, analytics-stack)
node scripts/cdk.mjs deploy infra --auto-approve
# Deploy all stacks to production
node scripts/cdk.mjs deploy all --prod --auto-approve
# Pull outputs from deployed stacks
node scripts/cdk.mjs outputs infra
# Full preparation: build + copy assets + pull outputs
node scripts/cdk.mjs prepare
# Bootstrap the CDKTF backend (S3 + DynamoDB)
node scripts/cdk.mjs bootstrap --auto-approveCommands:
status- Show current state of outputs and artifactsdeploy <stack|group>- Deploy stacks with dependency handlingoutputs <stack|group>- Pull outputs for deployed stacksbuild- Build all apps and copy assetsprepare- Full preparation: build + copy + pull outputssynth- Synthesize Terraform configurationlist- List available stacksdestroy <stack|group>- Destroy stacksbootstrap- Bootstrap the CDKTF backend
Groups: infra, lambdas, website, all
Flags:
--prod- Target production environment--auto-approve- Skip interactive prompts (required for CI/agents)--dry-run- Preview without executing--force- Force deployment even if validation fails
- List available sequences:
npm run sequence -- list - Run a sequence:
npm run sequence -- run <name> [--dry-run] - Current names:
build-deploy-api-lambda,deploy-infra,deploy-lambdas,full-deploy,clean-and-deploy,refresh-outputs
npm -w node-server run decrypt-envs
node scripts/cdk.mjs deploy myapp-api-lambda-stack --auto-approve
npm -w node-server run encrypt-envs
node scripts/cdk.mjs deploy infra --auto-approve
node scripts/cdk.mjs prepare
node scripts/cdk.mjs deploy all --auto-approve
npm run clean
npm i
node scripts/cdk.mjs prepare
node scripts/cdk.mjs deploy all --auto-approve
npm run test
- Preview backend-only tear‑out:
npm run eject:backend-only -- --dry-run - Apply backend-only tear‑out:
npm run eject:backend-only - Preview analytics tear‑out:
npm run eject:analytics -- --dry-run - Apply analytics tear‑out:
npm run eject:analytics - Preview users tear‑out:
npm run eject:users -- --dry-run - Apply users tear‑out:
npm run eject:users
node scripts/create-repository-service.mjs <entity-slug>
# Optional flags:
# --with handler Include optional scaffolding bundles (comma separated or "all")
# --dry-run Preview generated files without writing
# --force Overwrite existing files created in a previous run