Deploying
What happens in a deploy
Each deployment:
- clones the commit
- builds an image on your server, reusing cached layers
- runs the release command, such as
php artisan migrate --force - starts the new containers and waits for the health check
- switches traffic to them, then stops the old ones
If any step fails, the previous version keeps serving traffic. The deployment page shows each step and the live build log.
Environment and server
When importing, pick the project's Environment: Production, UAT, Staging or Development. It's a label that shows on the project and in the projects list, and you can change it in Settings → General. Choose or change the server it runs on in Settings → Server.
Triggers
- Push: every push to the project’s branch deploys, unless you turn off auto-deploy in Settings → General.
- Redeploy: deploys the same commit again, for example after changing environment variables.
- Deploy hook: a secret URL that deploys the latest commit when it receives a POST. Use it from CI, a CMS or a cron job. See Deploy hooks.
Rollback
Every successful deployment can be restored instantly from the Deployments page. Rolling back switches traffic to the earlier image without building. Database migrations aren't reverted.
Environment variables
Under Settings → Environment variables, add variables for the project’s own deploys (shown with its Environment, e.g. Production or UAT), for Preview, or both. In a shared variable group, the project’s own deploys are called Deploys. They're encrypted at rest and hidden in logs.
Variables starting with VITE_, NEXT_PUBLIC_ or REACT_APP_ are also available while building, because front-end code needs them. Their values end up in the browser bundle, so never put secrets in them.
You can paste a whole .env file at once. Every change is kept in the history. To share variables between projects, use Shared variables.
Processes
Hoist runs a web process, and for Laravel a queue worker (or Horizon) and the scheduler. Change them under Settings → Build, including the health check path.
Logs
The Logs page shows each process's output live, and the last hour, six hours or day.