VPSFolio

Stacks & Infra · Multi-App Stack · 2026-11-24

1 GB VPS Indie Dev Stack: Gitea, Uptime Kuma, and Miniflux Behind Caddy 2

Run private Git hosting, uptime monitoring, and an RSS reader together behind one Caddy 2 proxy on a 1 GB VPS.

Whole-stack run · 2026-11-24 Verified
Whole-stack RAM
451.1MB
Containers
5
Startup
153.5s
Target VPS
1 GB VPS
Co-hosted vs solo sum 451.1 MB together vs 448.2 MB summed separately (+2.9 MB / +0.6%)
Container breakdown gitea 196.8 MB · uptime-kuma 181.3 MB · miniflux 34.2 MB · miniflux-db 28.9 MB · caddy 9.9 MB
Verified reverse-proxy routes
  • Gitea via Caddy Host: git.local HTTP 200
  • Uptime Kuma via Caddy Host: status.local HTTP 302
  • Miniflux via Caddy Host: rss.local HTTP 200

Architecture and why these pieces fit together

This stack packs three self-hosted staples onto a single 1 GB VPS: Gitea for private Git hosting, Uptime Kuma for uptime monitoring, and Miniflux for RSS reading. All three sit behind one Caddy 2 reverse proxy that routes by hostname. Backend HTTP ports stay internal; only Caddy publishes a host port (bound to loopback for sandbox safety). Gitea SSH is exposed on a separate loopback port so you can push over SSH without opening the HTTP backends.

To keep memory in check we use SQLite for Gitea (no separate Postgres for Git) and a dedicated Postgres 16 instance for Miniflux. Uptime Kuma keeps its state in SQLite inside its data volume. The whole 5-container stack idled at 451.1 MB in our sandbox run — well under 550 MB, leaving headroom for spikes and the OS.

Caddy handles host-based routing with a tiny inline Caddyfile. In sandbox mode we disable automatic HTTPS and serve plain HTTP on port 80 inside the container, published to 127.0.0.1:18080 on the host. That lets you verify with curl -H "Host: git.local" http://127.0.0.1:18080/ without touching DNS or certificates. Production cutover is a small diff: remove auto_https off, switch to real domain names, and publish 80/443.

Prerequisites, ports, and VPS sizing

  • A 1 GB RAM VPS (1 vCPU is fine) running a modern Linux with Docker Engine 24+ and Docker Compose v2.
  • Ports on the host:
    • 18080 (loopback) for Caddy HTTP in sandbox mode. In production you’ll publish 80 and 443 instead.
    • 2222 (loopback) for Gitea SSH. Adjust GITEA_SSH_PORT if needed.
  • No host bind mounts. All persistent data lives in named volumes. Configs are inlined via Docker Compose configs:.
  • DNS (production): point git.example.com, status.example.com, and rss.example.com to your VPS IP. For local testing you can add entries to /etc/hosts pointing those names to 127.0.0.1.

Sizing notes: in our disposable sandbox run, the 5-container stack measured 451.1 MB total idle RAM (gitea 196.8 MB, uptime-kuma 181.3 MB, miniflux 34.2 MB, miniflux-db 28.9 MB, caddy 9.9 MB). That matches the 448.2 MB sum of our individual guides closely and leaves over 500 MB of OS/burst headroom on a 1 GB VPS (still add 1–2 GB of swap for Git pushes or monitor spikes).

Single-file Docker Compose setup

Create compose.yml and .env in a clean directory. The compose file uses top-level configs: to inline the Caddyfile, so there are no host bind mounts.

cat <<'EOF' > compose.yml
services:
  caddy:
    image: caddy:2-alpine
    restart: unless-stopped
    ports:
      - "127.0.0.1:${CADDY_HTTP_PORT:-18080}:80"
    configs:
      - source: caddyfile
        target: /etc/caddy/Caddyfile
    depends_on:
      - gitea
      - uptime-kuma
      - miniflux

  gitea:
    image: gitea/gitea:1.22
    container_name: gitea
    restart: unless-stopped
    environment:
      USER_UID: "1000"
      USER_GID: "1000"
      TZ: ${TZ:-UTC}
      GITEA__database__DB_TYPE: sqlite3
      GITEA__database__PATH: /data/gitea/gitea.db
      GITEA__server__DOMAIN: ${GITEA_DOMAIN:-git.local}
      GITEA__server__ROOT_URL: http://${GITEA_DOMAIN:-git.local}/
      GITEA__server__SSH_DOMAIN: ${GITEA_DOMAIN:-git.local}
      GITEA__server__SSH_PORT: ${GITEA_SSH_PORT:-2222}
      GITEA__server__HTTP_PORT: 3000
      GITEA__server__PROTOCOL: http
      GITEA__security__SECRET_KEY: ${GITEA_SECRET_KEY}
      GITEA__security__INTERNAL_TOKEN: ${GITEA_INTERNAL_TOKEN}
      GITEA__oauth2__JWT_SECRET: ${GITEA_JWT_SECRET}
      GITEA__service__DISABLE_REGISTRATION: "true"
    volumes:
      - gitea_data:/data
    ports:
      - "127.0.0.1:${GITEA_SSH_PORT:-2222}:22"

  uptime-kuma:
    image: louislam/uptime-kuma:2
    container_name: uptime-kuma
    restart: always
    volumes:
      - uptime-kuma:/app/data

  miniflux-db:
    image: postgres:16-alpine
    restart: unless-stopped
    environment:
      POSTGRES_USER: miniflux
      POSTGRES_PASSWORD: ${MINIFLUX_DB_PASSWORD}
      POSTGRES_DB: miniflux
      TZ: ${TZ:-UTC}
    volumes:
      - miniflux-db:/var/lib/postgresql/data
    healthcheck:
      test: ["CMD-SHELL", "pg_isready -U miniflux -d miniflux"]
      interval: 10s
      timeout: 5s
      retries: 10

  miniflux:
    image: miniflux/miniflux:latest
    restart: unless-stopped
    depends_on:
      miniflux-db:
        condition: service_healthy
    environment:
      DATABASE_URL: postgres://miniflux:${MINIFLUX_DB_PASSWORD}@miniflux-db:5432/miniflux?sslmode=disable
      RUN_MIGRATIONS: "1"
      BASE_URL: http://${MINIFLUX_DOMAIN:-rss.local}/
      LISTEN_ADDR: 0.0.0.0:8080
      TZ: ${TZ:-UTC}
    volumes:
      - miniflux-data:/var/lib/miniflux

configs:
  caddyfile:
    content: |
      {
        auto_https off
      }

      http://git.local {
        reverse_proxy gitea:3000
      }

      http://status.local {
        reverse_proxy uptime-kuma:3001
      }

      http://rss.local {
        reverse_proxy miniflux:8080
      }

volumes:
  gitea_data:
  uptime-kuma:
  miniflux-db:
  miniflux-data:
EOF

Generate .env with strong secrets. Replace the placeholder values before starting:

cat <<'EOF' > .env
# Timezone
TZ=UTC

# Caddy host port (loopback only in sandbox)
CADDY_HTTP_PORT=18080

# Gitea
GITEA_DOMAIN=git.local
GITEA_SSH_PORT=2222
GITEA_SECRET_KEY=replace-with-64-char-random
GITEA_INTERNAL_TOKEN=replace-with-105-char-random
GITEA_JWT_SECRET=replace-with-64-char-random

# Miniflux
MINIFLUX_DOMAIN=rss.local
MINIFLUX_DB_PASSWORD=replace-with-strong-db-password
EOF

Generate the random secrets with openssl rand -hex 32 (and openssl rand -hex 52 for the internal token). Then start the stack:

docker compose up -d
docker compose ps

Local verification before going live

Because Caddy is published on 127.0.0.1:18080 and routes by Host header, you can verify all three services without DNS changes:

curl -i -H "Host: git.local" http://127.0.0.1:18080/
curl -i -H "Host: status.local" http://127.0.0.1:18080/
curl -i -H "Host: rss.local" http://127.0.0.1:18080/

Expect HTTP 200 or 302 for each. Gitea may redirect to /user/login; Uptime Kuma serves its setup page; Miniflux redirects to /login. If any probe fails, check Caddy logs and backend logs:

docker compose logs caddy
docker compose logs gitea
docker compose logs uptime-kuma
docker compose logs miniflux

Common issues:

  • Gitea fails to start: confirm GITEA_SECRET_KEY, GITEA_INTERNAL_TOKEN, and GITEA_JWT_SECRET are set and long enough. Gitea refuses to start with weak or missing secrets.
  • Miniflux cannot connect to Postgres: verify MINIFLUX_DB_PASSWORD matches in both the miniflux-db service and the DATABASE_URL. The healthcheck should pass before Miniflux starts.
  • Uptime Kuma shows a setup screen: that’s expected on first run. Complete the admin account setup through the UI.

To test Gitea SSH, add a key in the Gitea UI and try ssh -T -p 2222 [email protected] (or your server IP).

Production cutover (HTTPS / remote backups)

When you’re ready to expose the stack on the public internet with real domains and TLS, make these changes:

  1. In compose.yml, update the Caddyfile config to remove auto_https off and use real hostnames:
 configs:
   caddyfile:
     content: |
-      {
-        auto_https off
-      }
-
-      http://git.local {
+      git.example.com {
         reverse_proxy gitea:3000
       }
-
-      http://status.local {
+      status.example.com {
         reverse_proxy uptime-kuma:3001
       }
-
-      http://rss.local {
+      rss.example.com {
         reverse_proxy miniflux:8080
       }
  1. Change the Caddy port mapping to publish 80 and 443:
     ports:
-      - "127.0.0.1:${CADDY_HTTP_PORT:-18080}:80"
+      - "80:80"
+      - "443:443"
  1. Update .env with your real domains and adjust Gitea/Miniflux base URLs:
-GITEA_DOMAIN=git.local
+GITEA_DOMAIN=git.example.com
-MINIFLUX_DOMAIN=rss.local
+MINIFLUX_DOMAIN=rss.example.com

Also switch GITEA__server__ROOT_URL to https://${GITEA_DOMAIN}/ and BASE_URL on Miniflux to https://${MINIFLUX_DOMAIN}/, and add persistent named volumes (caddy_data:/data and caddy_config:/config) to caddy so Let’s Encrypt certificates survive restarts.

  1. Restart the stack: docker compose up -d. Caddy will obtain certificates automatically via Let’s Encrypt. Ensure ports 80 and 443 are open in your firewall and that DNS A/AAAA records point to the VPS.

For remote backups, add a cron job or systemd timer that runs docker compose exec -T miniflux-db pg_dump -U miniflux miniflux > /backups/miniflux-$(date +%F).sql and similar for Gitea’s SQLite file (copy from the volume) and Uptime Kuma’s data directory. Store backups off-box (e.g., rclone to S3-compatible storage).

Day-2 operations, backups, and trade-offs

Backups. Gitea with SQLite stores everything in the gitea_data volume. Back it up by stopping Gitea briefly and copying /data/gitea/gitea.db and /data/git/repositories. For Miniflux, use pg_dump as above. Uptime Kuma’s SQLite database lives in the uptime-kuma volume; copy /app/data/kuma.db. Automate with a small script and test restores periodically.

Upgrades. Pin image tags (e.g., gitea/gitea:1.22, louislam/uptime-kuma:2, miniflux/miniflux:latest). For Miniflux, latest is convenient but consider pinning a specific version for reproducibility. Upgrade one service at a time: docker compose pull gitea && docker compose up -d gitea. Check logs and health before moving on. Gitea and Miniflux run migrations automatically; back up first.

Failure modes.

  • OOM killer: if you add many Uptime Kuma monitors or large Git repos, memory can spike. Monitor with docker stats and consider adding swap or moving to a 2 GB VPS.
  • Disk full: Git repos and Postgres data grow. Set up log rotation for Docker (/etc/docker/daemon.json with log-opts) and prune unused images.
  • Caddy certificate issues: ensure ports 80/443 are reachable and DNS is correct. Check docker compose logs caddy for ACME errors.

Trade-offs.

  • SQLite for Gitea simplifies the stack and saves RAM but limits concurrent write throughput. For a solo developer or small team it’s fine; for heavy CI or many users, switch to Postgres.
  • Sharing a single Postgres instance for Miniflux only (not Gitea) keeps isolation but uses a bit more RAM than a combined instance. If you’re tight on memory, you could run Gitea on the same Postgres by creating a separate database and user, but that adds complexity and couples failure domains.
  • Caddy’s automatic HTTPS is a huge win, but in sandbox mode we disable it. Remember to flip the switch for production.

Monitoring the monitor. Uptime Kuma can’t alert you if the whole VPS is down. Use an external ping service (e.g., Healthchecks.io) to watch Uptime Kuma’s /api/status-page/heartbeat endpoint or simply ping the Caddy status host. Keep an eye on docker compose ps and system logs.

With this stack you get a capable indie dev environment on a 1 GB VPS: private Git, uptime monitoring, and RSS reading, all behind one proxy, with room to grow.


Measured in our sandbox run: total memory 451.1 MB (sum of per-container peaks over a 30s idle window after startup) across 5 containers; largest container 196.8 MB; published port(s) 2222, 18080; HTTP probe returned 200, 302, 200. The run took 153.5s including the image download. Required secret(s) GITEA_INTERNAL_TOKEN, GITEA_JWT_SECRET, GITEA_SECRET_KEY, MINIFLUX_DB_PASSWORD were generated for the test run, as the tutorial instructs. Container breakdown: gitea 196.8 MB, uptime-kuma 181.3 MB, miniflux 34.2 MB, miniflux-db 28.9 MB, caddy 9.9 MB. Verified routes: Gitea via Caddy (HTTP 200), Uptime Kuma via Caddy (HTTP 302), Miniflux via Caddy (HTTP 200).


Verification: we ran this docker-compose stack in a disposable Docker environment and recorded the measurements above. They describe that run, not a guarantee for your host.