All posts devops
Coolify on Debian: A Production Setup Guide
Step-by-step walkthrough for installing Coolify on a bare Debian VPS, configuring Traefik, and deploying your first Dockerized app.
Brandon 12 min read
Coolify on Debian
Coolify is an open-source, self-hostable alternative to Heroku and Render. It manages Docker containers, handles SSL via Let's Encrypt, and gives you a clean UI for deployments.
Prerequisites
- A Debian 12 (Bookworm) VPS with at least 2 GB RAM
- A domain pointed at your server's IP
- SSH access as a non-root user with
sudo
Installation
bash
# One-liner from the official docs
curl -fsSL https://cdn.coollabs.io/coolify/install.sh | bash
Coolify installs Docker, docker-compose, and a Traefik reverse proxy automatically.
Configuring Your First App
- Navigate to
https://your-server:8000 - Create a new Project and Environment
- Add a New Resource → Application → GitHub
- Point it at your repo and set the build pack to Dockerfile
Coolify will detect your Dockerfile, build it, and expose the app via Traefik with a free SSL cert.
Environment Variables
Set secrets in the Coolify UI under Environment Variables, not in your repo. Coolify injects them as Docker --env flags at runtime.
bash
SITE_URL=https://blog.justbrain.org
NUXT_SECRET_KEY=your-secret-here
Health Checks
Add a /health route to your Nitro server and configure it in Coolify:
code
Health check path: /health
Interval: 30s
Timeout: 5s
Retries: 3
Coolify will automatically restart unhealthy containers.