Deployments and restarts

Understand the serialized deployment queue, rollout order, HTTP readiness checks, Git commit statuses, and safe rollbacks.

Choose Deploy for an initial release and Deploy/Redeploy after any repository commit, environment edit, volume change, or resource plan update. Track progress on the application's Deployments tab or across the whole organization under Deployments.

Deployment pipeline stages

Every deployment flows sequentially through five tracked stages:

  1. Resolve source: Pins a Git commit SHA (and branch/author metadata) or resolves the target container image digest.
  2. Enqueue work: Persists an idempotent job in Formatio's PostgreSQL queue, serialized per application so concurrent pushes never race.
  3. Build or pull: Compiles source via Railpack/Nixpacks/Dockerfile (injecting OTel where enabled) or pulls the specified registry image.
  4. Apply runtime config: Updates the target workload on Docker Swarm, Kubernetes, AWS ECS, or Google Cloud Run with secrets, networks, volumes, and labels.
  5. Watch readiness: Monitors container startup and HTTP/image health checks before recording Successful or Failed.

Choosing between deploy, restart, and rollback

Action Rebuilds or pulls image Applies saved env / plan / volume edits Available via /mcp
Deploy / Redeploy Yes Yes deploy_application
Restart No (replaces existing tasks as-is) No restart_application
Rollback Pulls the exact image from a prior Successful deployment without rebuilding Uses current variables, secrets, routes and volumes rollback_application

In the application's Deployments tab, select Roll back next to a previous successful deployment. You can also use rollback_application over MCP. The target must belong to the same application and have a recorded image digest. The rollback gets its own deployment ID and applies current settings; it does not restore old credentials or volume data.

Deployments made before image digests were recorded are not exact-image rollback targets. If the registry no longer has the recorded image, rollback fails before changing the running workload.

Readiness checks and zero-downtime ordering

Service updates use start-first ordering one task at a time and automatically halt/roll back on container healthcheck failure. Because old and new tasks briefly overlap during cutover, ensure startup scripts and database migrations handle brief overlap safely.

  • Image healthchecks: Used automatically unless overridden.
  • API HTTP readiness override: Setting healthcheck_path (e.g., /healthz) and healthcheck_port inside build_system_config via the HTTP API checks inside the container using wget or curl over /bin/sh.

Commit statuses on your Git provider

  • GitHub: Displays formatio/<application> commit status (pending, success, failure) once Commit statuses permission is approved on the App installation.
  • GitLab: Reports status (running, success, failed) onto the commit pipeline; can be toggled off from the Git connection card.
  • Bitbucket & Azure DevOps: Publishes per-application build statuses directly onto pushed commits. Missing status permissions never fail a deployment.

Handling interrupted or stuck queue jobs

Avoid clicking Deploy repeatedly when an attempt waits behind a running build. Inspect Build logs first. If an executor host crashes mid-deploy, administrators inspect and resolve uncertain queue jobs safely via Cluster or POST /api/deployment/queue/{id}/resolve/. See cluster administration.

Further reading