Replace @vercel/postgres, Blob, and Upstash with lib/sql.js, MinIO object storage, and CT 102 Redis rate limits. Add Dockerfile for Dokploy deploy, homelab runbooks, Neon data-copy helper, and point CI smoke/visual at the homelab URL instead of Vercel previews. Co-authored-by: Cursor <cursoragent@cursor.com>
2.5 KiB
2.5 KiB
Deck Hearth on Dokploy (CT 112)
Homelab deploy: Postgres + Redis + MinIO on CT 102, app on Dokploy, public URL via CT 100 Traefik → CT 112.
1. Prerequisites (CT 102)
deckhearthPostgres —provision-deckhearth.sh- MinIO bucket —
provision-deckhearth-minio.sh(axiom-server) - Neon data copy —
npm run migrate-neon-to-homelab(optional)
2. Dokploy application
Dashboard: https://dokploy.stillwell.cloud
| Setting | Value |
|---|---|
| Source | Git (Forgejo/GitHub) → this repo |
| Build type | Dockerfile |
| Dockerfile path | Dockerfile (repo root — must be pushed to GitHub) |
| Branch | homelab migration branch until merged to main |
| Domain in Dokploy | http://deckhearth.stillwell.cloud (use http://, not https://) |
| Port | 3000 |
3. Environment variables (Dokploy → Environment)
# Database (CT 102)
POSTGRES_URL=postgresql://deckhearth:YOUR_PASSWORD@192.168.68.102:5432/deckhearth
# Redis rate limits (CT 102, DB index 5)
REDIS_URL=redis://:YOUR_REDIS_PASSWORD@192.168.68.102:6379/5
# MinIO object storage (CT 102)
S3_ENDPOINT=http://192.168.68.102:9000
S3_ACCESS_KEY_ID=deckhearth-app
S3_SECRET_ACCESS_KEY=YOUR_MINIO_SECRET
S3_BUCKET=deckhearth
S3_PUBLIC_BASE_URL=https://cdn.stillwell.cloud/deckhearth
S3_REGION=us-east-1
# Auth
JWT_SECRET=openssl rand -base64 32
# AI (kept on Vercel AI Gateway)
AI_GATEWAY_API_KEY=vck_…
# Email (external — Resend until self-hosted)
RESEND_API_KEY=re_…
# Cron (n8n on CT 105 hits this weekly)
CRON_SECRET=openssl rand -base64 24
# Optional
NODE_ENV=production
4. Traefik (CT 100)
Route added in axiom-server/proxmox/ct100/traefik/config/dynamic/ct112-dokploy.yml:
- Host:
deckhearth.stillwell.cloud - Backend:
http://192.168.68.112:80(Dokploy Traefik)
After editing locally: ./proxmox/scripts/sync.sh push-traefik
5. Catalog sync cron (replaces Vercel Cron)
Vercel vercel.json crons are removed. Schedule in n8n (CT 105) or cron:
curl -fsS -H "Authorization: Bearer $CRON_SECRET" \
https://deckhearth.stillwell.cloud/api/cron/sync-catalog
Weekly: 0 6 * * 1 (Mondays 06:00).
6. Decommission Vercel
- Point DNS / AdGuard rewrite for
deckhearth.stillwell.cloudat Traefik (already*.stillwell.cloud→ CT 100). - Disable Vercel project auto-deploy or delete project after Coolify/Dokploy is stable.
- Remove unused env vars from Vercel dashboard (Neon, Blob, Upstash).
7. Local dev
Same env vars in .env.local with homelab URLs (LAN required).
npm run dev