From b3cd8a8914dbfe7f50b0d4fcb3161377b4cfb7d6 Mon Sep 17 00:00:00 2001 From: Neeldhara Misra Date: Sat, 13 Jun 2026 20:03:47 +0200 Subject: [PATCH] Attach Dokploy compose service to proxy network --- DEPLOYMENT.md | 12 ++++++++++++ docker-compose.yml | 6 ++++++ 2 files changed, 18 insertions(+) diff --git a/DEPLOYMENT.md b/DEPLOYMENT.md index accb7ce..ecf4f6b 100644 --- a/DEPLOYMENT.md +++ b/DEPLOYMENT.md @@ -72,6 +72,8 @@ Use the Docker Compose deployment path. The container builds all seven sites with `npm run build`. Nginx reads the `Host` header and serves the matching directory using `deploy/nginx.conf`. +The Compose app attaches to Dokploy's external `dokploy-network` so Dokploy's proxy can reach the container. If your Dokploy installation uses a different proxy network name, update `docker-compose.yml`. + ## DNS Point these DNS records at the Dokploy host: @@ -100,3 +102,13 @@ curl -I https://puzzles.neeldhara.blog/rss.xml ``` Expected result: `200 OK` for each. + +## Bad Gateway Checklist + +If Dokploy shows `Bad Gateway`: + +1. Confirm the app deployment finished successfully and the `blogs` container is running. +2. In the domain settings, make sure each domain points to service `blogs` and container port `80`. +3. Confirm the service is attached to `dokploy-network`. +4. Check the container logs. Nginx should stay in the foreground; if it exits, the logs should show the config error. +5. Redeploy after any Compose change so Dokploy recreates the container/network attachment. diff --git a/docker-compose.yml b/docker-compose.yml index e2923d4..82a1474 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -5,9 +5,15 @@ services: restart: unless-stopped expose: - "80" + networks: + - dokploy-network healthcheck: test: ["CMD", "wget", "-q", "--spider", "http://127.0.0.1/nginx-health"] interval: 30s timeout: 3s retries: 3 start_period: 10s + +networks: + dokploy-network: + external: true