Self-Host Like a Pro: Dokku, Hetzner and Cloudflare
a year ago
- #Cloudflare
- #VPS
- #Dokku
- Choose Hetzner VPS location and OS (e.g., Debian for unattended upgrades).
- Select machine type (e.g., CX22 with 2 vCPUs, 4GB RAM, 40GB SSD).
- Configure SSH key for secure access (Ed25519 algorithm recommended).
- Install Dokku for app deployment and PostgreSQL for database needs.
- Set up Cloudflare for DDoS protection and caching.
- Secure VPS by restricting port access (80, 443, 22) via firewall rules.
- Deploy app to Dokku, link PostgreSQL database, and set environment variables.
- Configure domain and SSL with Let's Encrypt for HTTPS.
- Automate deployments using GitHub Actions with SSH key authentication.