← blog JORGEMAYOR.IS-A.DEV
2025-01-15 · 5 min read
SELF-HOSTING FROM SCRATCH WITH ARCH LINUX AND DOCKER

A few weeks ago I decided to stop paying for hosting and run my own server from home. This is how I did it and what I learned along the way.

// why self-host

The main reason is control. When you self-host, you own the hardware, the software, the data, and the configuration. Nothing changes unless you change it. There are no surprise price increases, no terms of service updates, no vendor lock-in.

The second reason is learning. Setting up a real server from scratch teaches you more about how the internet works than any course or tutorial.

// the hardware

I'm using a mini PC running Arch Linux. Low power consumption, silent, and more than enough for a personal site and a few services. The whole setup costs less than a VPS per year after the initial hardware investment.

// the stack

Everything runs in Docker containers managed with Docker Compose. Nginx acts as a reverse proxy, handling all incoming traffic and routing it to the right container. Let's Encrypt provides free SSL certificates via Certbot.

internet → nginx (80/443) → containers
                     ↓
              let's encrypt (ssl)

// what I learned

DNS is simpler than it looks. Port forwarding is the part most people get wrong. And docker exec nginx nginx -s reload is a command you'll type a lot.

If you're thinking about self-hosting, just start. The first working setup is the hardest part. Everything after that is just adding more containers.

ONLINE SELF-HOSTED · ARCH LINUX · DOCKER