Files
20260512-skg-tk/docs/deploy-vps.md
2026-05-15 14:53:34 +08:00

1.6 KiB

SKG Marketing Studio VPS Deployment

Production domain:

  • App: https://marketing.skg.com
  • API: https://marketing.skg.com/api

Current VPS target:

  • Host: 76.13.31.179
  • OS: Ubuntu 24.04
  • Runtime: Docker Compose
  • Public ingress: existing Coolify Traefik on ports 80/443

DNS:

marketing.skg.com A 76.13.31.179

Do not run a host Nginx on ports 80/443. Those ports are already owned by Coolify / Traefik. This project publishes through Docker labels on the external coolify network.

First Deploy

On the VPS:

mkdir -p /opt/skg-marketing-studio
cd /opt/skg-marketing-studio
cp deploy/.env.production.example deploy/.env.production

Fill deploy/.env.production with the real production keys. Keep this file out of git.

Then start:

docker compose -f docker-compose.prod.yml --env-file deploy/.env.production up -d --build

Verify:

curl -I https://marketing.skg.com
curl https://marketing.skg.com/api/health
docker compose -f docker-compose.prod.yml ps

Update

Sync the repo to /opt/skg-marketing-studio, then run:

docker compose -f docker-compose.prod.yml --env-file deploy/.env.production up -d --build

Runtime Notes

  • web is a static Next export served by Nginx.
  • web proxies /api/ to skg-marketing-api:4291; avoid the generic hostname api because the web container also joins the shared Coolify network.
  • api is only on the internal project network and stores jobs under /data/jobs.
  • Server-side job files persist in ./data/jobs on the VPS.
  • Large uploads are allowed up to 2g at the Nginx proxy layer.