Remove nginx service from Coolify stack; update deployment guide to use frontend service on port 12001
Co-authored-by: Copilot <copilot@github.com>
This commit is contained in:
@@ -37,18 +37,6 @@ services:
|
|||||||
expose:
|
expose:
|
||||||
- "12001"
|
- "12001"
|
||||||
|
|
||||||
nginx:
|
|
||||||
image: nginx:alpine
|
|
||||||
volumes:
|
|
||||||
- ./nginx/docker-compose.conf:/etc/nginx/conf.d/default.conf:ro
|
|
||||||
depends_on:
|
|
||||||
- backend
|
|
||||||
- frontend
|
|
||||||
networks:
|
|
||||||
- app-network
|
|
||||||
expose:
|
|
||||||
- "80"
|
|
||||||
|
|
||||||
networks:
|
networks:
|
||||||
app-network:
|
app-network:
|
||||||
driver: bridge
|
driver: bridge
|
||||||
|
|||||||
@@ -57,7 +57,7 @@ Use Coolify's **Docker Compose** resource with the dedicated compose file `docke
|
|||||||
3. Select the `ai.allucanget.biz` repository and `main` branch
|
3. Select the `ai.allucanget.biz` repository and `main` branch
|
||||||
4. Set **Compose File** to `docker-compose.coolify.yml`
|
4. Set **Compose File** to `docker-compose.coolify.yml`
|
||||||
5. Set **Base Directory** to `/`
|
5. Set **Base Directory** to `/`
|
||||||
6. Select the `nginx` service as the public-facing service on port `80`
|
6. Select the `frontend` service as the public-facing service on port `12001`
|
||||||
7. Click **Create Resource**
|
7. Click **Create Resource**
|
||||||
|
|
||||||
### Step 2: Configure Environment Variables
|
### Step 2: Configure Environment Variables
|
||||||
@@ -76,11 +76,11 @@ Add these in Coolify before first deploy:
|
|||||||
|
|
||||||
### Step 3: Configure Domain and Proxy
|
### Step 3: Configure Domain and Proxy
|
||||||
|
|
||||||
1. Attach domain `ai.allucanget.biz` to `nginx` service
|
1. Attach domain `ai.allucanget.biz` to the `frontend` service on port `12001`
|
||||||
2. Enable **Auto HTTPS** in Coolify
|
2. Enable **Auto HTTPS** in Coolify
|
||||||
3. Let Coolify terminate TLS and forward traffic to `nginx:80`
|
3. Coolify terminates TLS and forwards traffic directly to `frontend:12001`
|
||||||
|
|
||||||
`docker-compose.coolify.yml` does not publish host ports `80/443`. This avoids conflicts with Coolify's own proxy while keeping backend and frontend reachable over internal Docker network.
|
No nginx service is needed in the Coolify stack. The frontend Flask app proxies `/api/*` calls to `http://backend:12000` internally. Coolify's own reverse proxy handles external TLS termination.
|
||||||
|
|
||||||
### Step 4: Persistent Storage
|
### Step 4: Persistent Storage
|
||||||
|
|
||||||
@@ -222,8 +222,8 @@ If you want to persist DuckDB data:
|
|||||||
### Docker Compose deployment fails in Coolify
|
### Docker Compose deployment fails in Coolify
|
||||||
|
|
||||||
- Verify Coolify uses `docker-compose.coolify.yml`, not local `docker-compose.yml`
|
- Verify Coolify uses `docker-compose.coolify.yml`, not local `docker-compose.yml`
|
||||||
- Verify public domain points to `nginx` service on port `80`
|
- Verify public domain points to `frontend` service on port `12001`
|
||||||
- Do not publish host ports `80:80` or `443:443` inside Coolify stack
|
- Do not add `nginx` to the Coolify stack — bind-mounting a local config file will fail since the file doesn't exist on the Coolify server
|
||||||
|
|
||||||
### Backend healthcheck stays unhealthy
|
### Backend healthcheck stays unhealthy
|
||||||
|
|
||||||
@@ -272,7 +272,7 @@ All required environment variables:
|
|||||||
|
|
||||||
- [ ] Repository pushed to Git
|
- [ ] Repository pushed to Git
|
||||||
- [ ] For Docker Compose: Coolify resource uses `docker-compose.coolify.yml`
|
- [ ] For Docker Compose: Coolify resource uses `docker-compose.coolify.yml`
|
||||||
- [ ] For Docker Compose: domain points to `nginx` service on port `80`
|
- [ ] For Docker Compose: domain points to `frontend` service on port `12001`
|
||||||
- [ ] Backend service created with correct base directory (`/backend`)
|
- [ ] Backend service created with correct base directory (`/backend`)
|
||||||
- [ ] Backend environment variables configured
|
- [ ] Backend environment variables configured
|
||||||
- [ ] Frontend service created with correct base directory (`/frontend`)
|
- [ ] Frontend service created with correct base directory (`/frontend`)
|
||||||
|
|||||||
Reference in New Issue
Block a user