Rebuild Docker, Compose and Drone CI configuration
This commit is contained in:
@@ -1,59 +1,49 @@
|
||||
version: '3.8'
|
||||
version: '3.8'
|
||||
|
||||
services:
|
||||
# Backend сервис
|
||||
backend:
|
||||
image: registry.nevetime.ru/mc-panel-backend:${IMAGE_TAG:-latest}
|
||||
image: ${BACKEND_IMAGE:-registry.nevetime.ru/mc-panel-backend:${IMAGE_TAG:-latest}}
|
||||
container_name: mc-panel-backend
|
||||
restart: unless-stopped
|
||||
ports:
|
||||
- "8000:8000"
|
||||
environment:
|
||||
- PORT=8000
|
||||
- WORKERS=2
|
||||
- PYTHONPATH=/app
|
||||
- DEBUG=false
|
||||
env_file:
|
||||
- ./backend/.env
|
||||
environment:
|
||||
PORT: ${BACKEND_PORT:-8000}
|
||||
WORKERS: ${BACKEND_WORKERS:-2}
|
||||
volumes:
|
||||
- mc_servers:/app/servers
|
||||
- mc_data:/app/data
|
||||
- mc_logs:/app/logs
|
||||
networks:
|
||||
- mc-panel-network
|
||||
- mc-panel
|
||||
healthcheck:
|
||||
test: ["CMD", "curl", "-f", "http://localhost:8000/health"]
|
||||
test: ["CMD", "curl", "-fsS", "http://localhost:8000/health"]
|
||||
interval: 30s
|
||||
timeout: 10s
|
||||
retries: 3
|
||||
start_period: 60s
|
||||
|
||||
# Frontend сервис
|
||||
frontend:
|
||||
image: registry.nevetime.ru/mc-panel-frontend:${IMAGE_TAG:-latest}
|
||||
image: ${FRONTEND_IMAGE:-registry.nevetime.ru/mc-panel-frontend:${IMAGE_TAG:-latest}}
|
||||
container_name: mc-panel-frontend
|
||||
restart: unless-stopped
|
||||
ports:
|
||||
- "80:80"
|
||||
- "${FRONTEND_PORT:-80}:80"
|
||||
depends_on:
|
||||
- backend
|
||||
backend:
|
||||
condition: service_healthy
|
||||
networks:
|
||||
- mc-panel-network
|
||||
- mc-panel
|
||||
healthcheck:
|
||||
test: ["CMD", "curl", "-f", "http://localhost/health"]
|
||||
test: ["CMD", "wget", "-qO-", "http://localhost/health"]
|
||||
interval: 30s
|
||||
timeout: 10s
|
||||
retries: 3
|
||||
start_period: 30s
|
||||
|
||||
volumes:
|
||||
mc_servers:
|
||||
driver: local
|
||||
mc_data:
|
||||
driver: local
|
||||
mc_logs:
|
||||
driver: local
|
||||
|
||||
networks:
|
||||
mc-panel-network:
|
||||
driver: bridge
|
||||
mc-panel:
|
||||
driver: bridge
|
||||
|
||||
Reference in New Issue
Block a user