Deployment

The API is deployed to Azure Container Apps via GitHub Actions. Pushing to a deployment branch automatically builds a container image, pushes it to an Azure Container Registry, and rolls out the matching Container App.

Environments

Each environment auto-deploys from its own Git branch. Development/testing lives in a separate Azure subscription from staging and production (different registry and resource group).

EnvironmentBranchContainer AppResource groupContainer registry
Productionproductionpublic-api-productionre-container-apps-productionpedalheadsveloacr.azurecr.io
Stagingstagingpublic-api-stagingre-container-appspedalheadswebsiteacr.azurecr.io
Development / Testingtestingpublic-website-api-2026-devrg-atlantis-devpedalheadsdevelopment.azurecr.io
  • Production URL: https://api.pedalheads.com, served through Cloudflare.
  • Image tag: each build is tagged with the commit SHA (e.g. pedalheadsveloacr.azurecr.io/public-api-production:<github.sha>).
  • Each environment authenticates to Azure with its own set of GitHub secrets (client/tenant/subscription IDs, registry credentials).
  • Workflows live in .github/workflows/.

Release process

  1. Run migrations in the Cadence / Velo Admin app first. The admin app owns the shared database schema, so apply any migrations there before releasing the API. This ensures the API has every DB update the release depends on. The API does not run migrations.
  2. Push / merge to the appropriate deployment branch (testing, staging, or production).
  3. GitHub Actions builds and pushes the image and updates the Azure Container App.
  4. Verify the deployment using the readiness endpoint (see API Reference).

:::danger Migrations before release Always run migrations in Cadence / Velo Admin before releasing the API. The API should never run migrations against the shared database. :::

Production runtime

In the production image the app runs under Supervisor as a Laravel Octane (OpenSwoole) process:

php artisan octane:start --server=swoole --host=0.0.0.0 --port=9000 \
  --workers=$OCTANEWORKERS --task-workers=$OCTANETASKWORKERS \
  --max-requests=$OCTANEMAXREQUESTS

Worker counts and max-requests are controlled by the OCTANE* environment variables so they can be tuned per environment without changing the image.