Files
NeveTimePanel/docker-compose.yml
arkonsadter e02789ef53
All checks were successful
continuous-integration/drone/push Build is passing
fix(docker): resolve nginx and backend path configuration issues
- Add nginx/default.conf with simplified configuration to fix "no events section" error
- Update docker-compose.yml to mount nginx/default.conf instead of nginx.conf
- Fix backend/daemons.py data path from backend/data/daemons.json to data/daemons.json
- Improve users.json path detection with fallback logic in daemons.py
- Add servers directory to .gitignore
- Create DOCKER_FIX.md documentation with troubleshooting steps and solutions
- Ensure data directory is created automatically when backend starts
2026-01-17 10:32:46 +06:00

66 lines
1.7 KiB
YAML

version: '3.8'
services:
# MC Panel приложение
mc-panel:
build:
context: .
dockerfile: Dockerfile
container_name: mc-panel
restart: unless-stopped
ports:
- "8000:8000"
environment:
# ZITADEL OpenID Connect
- ZITADEL_ISSUER=${ZITADEL_ISSUER}
- ZITADEL_CLIENT_ID=${ZITADEL_CLIENT_ID}
- ZITADEL_CLIENT_SECRET=${ZITADEL_CLIENT_SECRET}
# URLs
- BASE_URL=${BASE_URL:-http://localhost:8000}
- FRONTEND_URL=${FRONTEND_URL:-http://localhost:3000}
# Security
- SECRET_KEY=${SECRET_KEY:-change-this-in-production}
# Python
- PYTHONUNBUFFERED=1
volumes:
# Персистентное хранилище для серверов
- ./data/servers:/app/backend/servers
# Персистентное хранилище для пользователей и тикетов
- ./data/users.json:/app/backend/users.json
- ./data/tickets.json:/app/backend/tickets.json
networks:
- mc-panel-network
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8000/api/auth/oidc/providers"]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s
# Nginx reverse proxy (опционально)
nginx:
image: nginx:alpine
container_name: mc-panel-nginx
restart: unless-stopped
ports:
- "80:80"
- "443:443"
volumes:
- ./nginx/default.conf:/etc/nginx/conf.d/default.conf:ro
- ./nginx/ssl:/etc/nginx/ssl:ro
depends_on:
- mc-panel
networks:
- mc-panel-network
networks:
mc-panel-network:
driver: bridge
volumes:
servers-data:
users-data: