chore: split Coolify compose configuration

This commit is contained in:
2026-06-08 13:30:18 +08:00
parent ad8fc7957e
commit 9024f80a70
4 changed files with 21 additions and 4 deletions

View File

@@ -13,7 +13,7 @@ npm run start # Start production server
npm run lint # ESLint (eslint-config-next/core-web-vitals + typescript) npm run lint # ESLint (eslint-config-next/core-web-vitals + typescript)
``` ```
Docker deployment: port 8019, `docker-compose up` with env supplied by the deployment platform or shell, external network `sinobridge`. Docker deployment: port 8019. Default `docker-compose.yml` uses `.env.production` and external network `sinobridge`; Coolify uses `docker-compose.coolify.yml` with runtime env from Coolify and external network `coolify`.
## Architecture ## Architecture

View File

@@ -74,7 +74,9 @@ The included Dockerfile builds a standalone Next.js output and starts `server.js
docker compose up -d --build docker compose up -d --build
``` ```
Set the required environment variables through your deployment platform or shell before starting Compose. The included `docker-compose.yml` expects an external Docker network named `sinobridge`. The default `docker-compose.yml` expects `.env.production` and an external Docker network named `sinobridge`.
For Coolify deployments, use `docker-compose.coolify.yml`. It expects runtime environment variables from Coolify and an external Docker network named `coolify`.
## Operational Notes ## Operational Notes

View File

@@ -0,0 +1,15 @@
services:
analytics:
build: .
container_name: new-api-analytics
restart: unless-stopped
ports:
- "8019:8019"
environment:
- SERVICE_URL_ANALYTICS_8019
networks:
- coolify
networks:
coolify:
external: true

View File

@@ -5,8 +5,8 @@ services:
restart: unless-stopped restart: unless-stopped
ports: ports:
- "8019:8019" - "8019:8019"
environment: env_file:
- SERVICE_URL_ANALYTICS_8019 - .env.production
networks: networks:
- sinobridge - sinobridge