Dokku
Docker powered mini-Heroku for easy git-push deployments to your own server.
Why consider Dokku?
Dokku is the smallest PaaS implementation that lets you push applications to your own server via git. It handles container builds, routing, SSL certificates, and scaling.
Learn Dokku by building
Practical setup notes, real use cases, and copy-ready examples in one focused guide.
In this guide10 sections
What is Dokku?
Dokku is an open-source Platform as a Service (PaaS) that runs on your own server hardware or single VPS. Often described as a "mini-Heroku," Dokku uses Docker and Buildpacks to turn any clean Linux instance into a self-hosted cloud platform where you can deploy web applications simply by running git push dokku main.
Dokku automates container building (via Cloud Native Buildpacks or Dockerfiles), reverse proxy routing with Nginx, automated SSL certificate issuance with Let's Encrypt, environment variable management, and zero-downtime rolling restarts.
Who Is It For?
- Full-Stack Developers: Deploying staging and production web apps (Node.js, Python, Ruby, Go, PHP) without paying high per-dyno SaaS fees.
- Freelancers & Digital Agencies: Hosting dozens of client websites on a single VPS with isolated containers and automated SSL.
- Indie Hackers & Startups: Bootstrapping SaaS products with Heroku-like workflow simplicity while retaining complete control over infrastructure costs.
Key Features
- Direct git-push deployment workflow using standard Cloud Native Buildpacks or custom Dockerfiles.
- Built-in Let's Encrypt plugin for automated zero-configuration SSL certificate generation and auto-renewal.
- Extensive official plugin ecosystem for one-command database provisioning (PostgreSQL, MySQL, Redis, MongoDB).
- Granular process scaling, port mapping, custom domain routing, and zero-downtime deployment checks.
- Native integration with Docker storage volumes and persistent host mounts.
Installation and Quick Start
Install Dokku on an Ubuntu or Debian server (minimum 1 GB RAM):
# Install the latest stable Dokku releasewget -NP . https://dokku.com/install/v0.38.27/bootstrap.shsudo DOKKU_TAG=v0.38.27 bash bootstrap.sh# Configure your SSH public key and global domaincat ~/.ssh/authorized_keys | sudo dokku ssh-keys:add adminsudo dokku domains:set-global dokku.example.comTo create and deploy your first application:
# 1. Create the application container on the Dokku serverdokku apps:create my-api# 2. Provision and link a PostgreSQL databasedokku plugin:install https://github.com/dokku/dokku-postgres.gitdokku postgres:create my-dbdokku postgres:link my-db my-api# 3. Add remote on your local machine and deploygit remote add dokku dokku@dokku.example.com:my-apigit push dokku mainPractical Use Cases
1. Multi-App Micro-PaaS
An engineering team runs 15 separate microservices (Next.js frontends, FastAPI backends, and Redis queues) on a single $20/month VPS, managing each with independent domain names and SSL.
2. Instant Database Provisioning
A developer tests a new web framework by running dokku postgres:create testdb && dokku postgres:link testdb my-app, which automatically injects DATABASE_URL into the container environment.
3. Staging and Review Environments
A continuous integration pipeline deploys pull requests to isolated preview URLs (pr-42.dokku.example.com) and tears them down after merging.
Troubleshooting and Limitations
- Single Host Scope: Dokku is designed for single-node deployments; for multi-node clustering across a server fleet, consider Kubernetes or Nomad.
- Build Memory Limits: Large Node.js or Rust builds can trigger out-of-memory (OOM) errors during compilation; configure server swap memory (
fallocate -l 2G /swapfile) before heavy builds.
Official Resources
- Official Website: https://dokku.com
- GitHub Repository: https://github.com/dokku/dokku
- Documentation: https://dokku.com/docs/
Related tools
More options with a similar category or technology profile.
Dapr CLI
Command-line tool for managing Dapr distributed application runtime environments and sidecars.
bpytop
Python port of bashtop with game-like UI, responsive mouse support, and hardware sensors.
bashtop
Linux resource monitor showing usage and stats for processor, memory, disks, network, and processes.
SchemaHero
Kubernetes-native declarative database schema management and table migration operator.