feat: Configure production Docker deployment with Nginx, health checks, and SQLite data persistence.
This commit is contained in:
@@ -3,10 +3,6 @@ services:
|
||||
build:
|
||||
context: .
|
||||
dockerfile: server/Dockerfile
|
||||
# Remove fixed port binding for production - let Coolify/reverse proxy handle routing
|
||||
# Uncomment below for local development:
|
||||
# ports:
|
||||
# - "3000:3000"
|
||||
expose:
|
||||
- "3000"
|
||||
volumes:
|
||||
@@ -15,22 +11,29 @@ services:
|
||||
- PORT=3000
|
||||
- ADMIN_PASSWORD=${ADMIN_PASSWORD:-123456}
|
||||
restart: unless-stopped
|
||||
healthcheck:
|
||||
test: ["CMD", "wget", "--no-verbose", "--tries=1", "--spider", "http://localhost:3000/api/health"]
|
||||
interval: 30s
|
||||
timeout: 3s
|
||||
retries: 3
|
||||
start_period: 10s
|
||||
|
||||
client:
|
||||
build:
|
||||
context: ./client
|
||||
dockerfile: Dockerfile
|
||||
# Remove fixed port binding for production - let Coolify/reverse proxy handle routing
|
||||
# Uncomment below for local development:
|
||||
# ports:
|
||||
# - "5173:5173"
|
||||
expose:
|
||||
- "5173"
|
||||
ports:
|
||||
- "80:80"
|
||||
depends_on:
|
||||
- server
|
||||
environment:
|
||||
- VITE_API_URL=http://server:3000
|
||||
server:
|
||||
condition: service_healthy
|
||||
restart: unless-stopped
|
||||
healthcheck:
|
||||
test: ["CMD", "wget", "--no-verbose", "--tries=1", "--spider", "http://localhost:80/"]
|
||||
interval: 30s
|
||||
timeout: 3s
|
||||
retries: 3
|
||||
start_period: 5s
|
||||
|
||||
volumes:
|
||||
eventy_data:
|
||||
|
||||
Reference in New Issue
Block a user