Deployments
Every time you deploy a project, Swisblade creates a deployment record that tracks the entire process from start to finish.
Deployment flow
When you click Deploy in the dashboard (or a deploy is triggered automatically):
- Git pull — Fetches the latest code from your configured branch/tag/SHA
- Validate — Checks that
stack.jsonis valid and all referenced services are properly configured - Sync contract — Detects changes to
stack.jsonsince the last deploy (new services, removed services, etc.) - Inject env vars — Reads your secrets from the dashboard, decrypts them, and prepares them for the containers
- Provision infrastructure — Sets up any databases, caches, or queues declared in
needs(if not already provisioned) - Build & start — Builds Docker images from your source code and starts all containers
Deployment states
| State | Description |
|---|---|
pending | Deploy queued |
running | Build and startup in progress |
success | All containers are running |
failed | Something went wrong — check the logs |
Viewing deploy logs
Real-time streaming
When a deploy is in progress, the dashboard streams logs in real time. You'll see each step as it happens: cloning, building, starting containers.
Historical logs
All deploy logs are persisted. Go to Project → Deployments to see the full log of any past deployment.
Failure diagnostics
If a deploy fails, Swisblade automatically captures:
- The last 15 lines of output from each failed container
- Error messages from the build step
- Missing environment variable warnings
This diagnostic information appears in the deploy log.
Triggering a redeploy
To redeploy with the latest code:
- Go to your project in the dashboard
- Click Deploy
Swisblade will pull the latest code from your configured ref, rebuild containers if the code changed, and restart the stack.
What triggers a rebuild
| Change | Rebuilds? |
|---|---|
| Source code changed | Yes |
stack.json changed | Yes (affected services only) |
| Environment variable changed | No (restart with new env, no rebuild) |
| No changes | Containers are restarted |
Environment variable validation
Before starting containers, Swisblade checks that all required environment variables have values. If your stack.json declares:
"env": {
"STRIPE_KEY": { "secret": true }
}
And you haven't set STRIPE_KEY in the dashboard, the deploy will fail with a clear message listing the missing variables.
Connection strings generated by the platform (like DATABASE_URL) are always present and don't need manual configuration.