Deployment
Step-by-step guide for deploying the Volāre backend and frontend to staging and production environments.
The backend ships as Docker images to AWS ECR, then deployed onto servers
via the infra-volare repository. The frontend deploys separately through
git-connected Cloudflare Workers Builds — see Frontend (Cloudflare Workers).
Overview (backend)
Section titled “Overview (backend)”Deploying the backend requires two sequential steps:
- Build — Docker images are built and uploaded to AWS ECR. This does not deploy anything — it only prepares the images. Builds trigger on PRs labeled
ready-to-test, onworkflow_dispatch, and on the new version tag created after a merge (see below). - Deploy (manual) — A developer triggers the deploy workflow from the
infra-volarerepository to put those images on a server.
The deploy process is the same for both staging and production — the only difference is the environment selected in the workflow.
Prerequisites
Section titled “Prerequisites”- Access to the infra-volare GitHub repository
- A merged PR in the
volarerepository (or a known image tag to deploy)
Automated Pipeline (after merge)
Section titled “Automated Pipeline (after merge)”When a PR is merged to master, the workflows in the volare Actions tab chain like this:
- Tag on Merge (
tag-on-merge.yml) — Creates a semantic version tag (e.g.,v1.3.0) from conventional commit messages, then dispatches the build workflow on that new tag. - Build & Push to ECR (
build-images.yml) — Builds the Docker images and pushes them to AWS ECR, tagged with the version. Images built:php-fpm,queue-worker,backend(nginx), andfrontend, plusphp-base,analytics-mcp, and the Nightwatch agent. (The build workflow also runs directly on PRs labeledready-to-test, so images can be tested before merge.)
Before deploying, verify both workflows completed successfully in the Actions tab. The version tag created (e.g., v1.3.0) is the value you will use as the image tag when deploying. You can find it in the repository tags.
Deploying
Section titled “Deploying”Once images are built and available in ECR, trigger the deploy:
- Go to infra-volare Actions
- Select the Deploy infrastructure workflow
- Click Run workflow
- Fill in the form:
| Field | Description | Example |
|---|---|---|
| Environment to deploy | Target environment | staging-1 or production-1 |
| Frontend image tag | Version tag for the frontend image | v1.3.0 |
| Backend image tag | Version tag for the backend image | v1.3.0 |
- (Optional) Check “Only run plan, do not apply” to preview infrastructure changes without deploying
- Click Run workflow
- There is no required order between staging and production. You can deploy directly to production if needed.
- Use the
sha-<commit>tag format if you need to deploy a specific commit that is not a release. - The Frontend image tag field may be vestigial: the frontend now deploys through Cloudflare Workers Builds, not the ECR image (though a
frontendECR image is still built). Confirm current behavior in theinfra-volaredeploy workflow before relying on it.
Frontend (Cloudflare Workers)
Section titled “Frontend (Cloudflare Workers)”The Astro frontend deploys via git-connected Cloudflare Workers Builds — no manual image tag step (introduced in PR #2221).
- Adapter:
@astrojs/cloudflareis selected at build time whenDEPLOY_TARGET=cloudflare(Node adapter otherwise). Seefrontend/astro.config.mjs. - Worker config:
frontend/wrangler.jsonc— declares theSESSION_KVKV binding,nodejs_compat, and observability. There is no custom domain / route; the Worker is reachable only viaworkers.devURLs. - Package manager: pinned to
pnpm@11.0.8viapackageManagerinfrontend/package.json. - Branch behavior:
master→ production deploy- other branches → per-branch
workers.devpreview URLs (no staging custom domain, keeping staging off any indexable hostname)
- Secrets/variables (
API_URL,GTM_ID,INTERNAL_API_TOKEN) are managed viawrangler secret putor the Cloudflare dashboard — not committed.
Post-deploy Verification
Section titled “Post-deploy Verification”After the workflow completes, verify the deployment is healthy:
Health Endpoint
Section titled “Health Endpoint”# Replace with the actual environment URLcurl https://<environment-url>/healthA 200 response with all checks ok confirms the deployment is healthy. See Health Monitoring for details on available checks.
Monitoring Dashboards
Section titled “Monitoring Dashboards”- Telescope (
/telescope) — Look for new exceptions or errors after the deploy - Sentry — Error and performance tracking (
sentry/sentry-laravel) - Nightwatch — Application performance monitoring via the agent container
Rollback
Section titled “Rollback”To roll back a deployment, run the deploy workflow again with the previous version tag. The containers will be replaced with the earlier image.
Related Documentation
Section titled “Related Documentation”- Docker Health Monitoring — Container runtime and health checks
- Health Monitoring — Application health endpoints and dashboards