Infrastructure and Delivery
Alternun provisions infrastructure from the monorepo through packages/infra.
The project uses:
- SST as the app wrapper and deployment entrypoint
- Pulumi AWS resources inside the infra modules
- CodeBuild and CodePipeline for managed delivery flows
- Route53 and ACM for DNS and certificates
Stage Model
The platform is split into several deployment families.
Public AIRS stages
productiondevmobile
Default public domains:
airs.alternun.cotestnet.airs.alternun.copreview.airs.alternun.co
Backend and internal stages
dashboard-devdashboard-prodadmin-devadmin-prodidentity-devidentity-prod
These let the team deploy internal surfaces independently or as a combined release unit.
Retired stage aliases:
api-dev,api-prodbackend-dev,backend-prodbackend-api-dev,backend-api-prod
Those old backend-only aliases normalize to the dashboard stacks in local tooling and must not be used as standalone live deploy targets.
Domain Model
The current domain family separates public product surfaces from marketing surfaces.
Notable detail:
- the public marketing/corporate site stays on
alternun.io - application and identity surfaces use the
alternun.codomain family
What The Infra Package Provisions
Public app delivery
For AIRS, the infra package provisions:
- static site delivery for the Expo web build
- asset buckets
- CloudFront-backed distribution path
- stage-aware redirects
- release-update manifest and worker assets generated from the current package version
Frontend deploys also depend on stage-scoped public auth config coming from AWS SSM Parameter Store. For the public AIRS bundles, EXPO_PUBLIC_AUTH_EXECUTION_PROVIDER and EXPO_PUBLIC_BETTER_AUTH_URL must be set in SSM for each frontend stage, especially dev/testnet and production, so the exported bundle stays aligned with the owning API/auth runtime instead of relying on inferred defaults.
For EXPO_PUBLIC_BETTER_AUTH_URL, keep the value browser-facing on the stage API origin root such as https://testnet.api.alternun.co or https://api.alternun.co; the client and proxy layers append /auth internally.
Backend API delivery
For the custom API, the infra package provisions:
- Lambda
- API Gateway HTTP API
- CloudWatch logging
- custom domain mapping
- ACM and DNS validation when needed
Database changes for the live backend are handled separately from stack deploys:
- preview with
scripts/sync-db-migrations.sh <stage> --dry-run - apply exactly one reviewed migration file at a time with
--file - use
--force-prodfor any production migration apply - do not batch-apply the full backlog unless you are doing a deliberate recovery run
Admin delivery
For the admin console, the infra package provisions:
- static site hosting
- CDN distribution
- custom domains and certificates