The Self-Hosting Stack

Four articles that build one working server: a hardened Ubuntu host, an application deployed with Docker Compose, deploys that do not drop requests, and backups you have actually restored.

Intermediate vps 4 parts · about 17 min total

Self-hosting fails in a predictable order. The firewall looks correct but does not cover published container ports. The application deploys, but every release drops requests for a few seconds. Backups run nightly for a year and cannot be restored.

This series works through those four problems in the order you hit them.

Each part stands alone — you can read the backup article without the hardening one — but the versions and file layout are consistent across all four, so following them in order gives you one coherent server rather than four different conventions.

  1. How to Secure a VPS That Runs Docker Containers

    SSH hardening, a default-deny firewall, and the fix for the problem that catches almost everyone — Docker publishing container ports straight past UFW into the public internet.

    · 4 min · Intermediate

  2. How to Deploy n8n on an Ubuntu VPS with Docker

    A production n8n install on Ubuntu 24.04 using Docker Compose, PostgreSQL and Caddy for automatic TLS — with the encryption key, webhook URL and backup steps most quickstarts leave out.

    · 5 min · Intermediate

  3. Zero-Downtime Deploys in Dokploy with Docker Health Checks

    Dokploy runs apps as Docker Swarm services, so rolling updates are already there — they just need a real health check and an update policy. Plus how to prove no request was dropped.

    · 4 min · Advanced

  4. How to Back Up Docker Volumes Automatically

    A nightly backup for a self-hosted Docker host: database dumps taken with the right tools, file volumes snapshotted with restic, a systemd timer to run it, and a restore test that proves it works.

    · 4 min · Intermediate