Spaces:
Configuration error
Configuration error
| services: | |
| postgres: | |
| image: postgres:15-alpine | |
| container_name: gmail2_postgres_prod | |
| restart: always | |
| environment: | |
| POSTGRES_USER: postgres | |
| POSTGRES_PASSWORD: postgres | |
| POSTGRES_DB: gmail2 | |
| ports: | |
| - "5432:5432" | |
| volumes: | |
| - pgdata:/var/lib/postgresql/data | |
| mongodb: | |
| image: mongo:6-jammy | |
| container_name: gmail2_mongodb_prod | |
| restart: always | |
| ports: | |
| - "27017:27017" | |
| volumes: | |
| - mongodata:/data/db | |
| redis: | |
| image: redis:7-alpine | |
| container_name: gmail2_redis_prod | |
| restart: always | |
| ports: | |
| - "6379:6379" | |
| backend: | |
| build: | |
| context: ./backend | |
| dockerfile: Dockerfile | |
| container_name: gmail2_backend_prod | |
| restart: always | |
| ports: | |
| - "8000:8000" | |
| env_file: | |
| - .env | |
| environment: | |
| - DATABASE_URL=postgresql+asyncpg://postgres:postgres@postgres:5432/gmail2 | |
| - MONGODB_URI=mongodb://mongodb:27017/ | |
| - REDIS_HOST=redis | |
| - REDIS_PORT=6379 | |
| depends_on: | |
| - postgres | |
| - mongodb | |
| - redis | |
| celery_worker: | |
| build: | |
| context: ./backend | |
| dockerfile: Dockerfile | |
| container_name: gmail2_celery_worker_prod | |
| restart: always | |
| command: celery -A app.tasks.celery_app.celery_app worker --loglevel=info -P solo | |
| env_file: | |
| - .env | |
| environment: | |
| - DATABASE_URL=postgresql+asyncpg://postgres:postgres@postgres:5432/gmail2 | |
| - MONGODB_URI=mongodb://mongodb:27017/ | |
| - REDIS_HOST=redis | |
| - REDIS_PORT=6379 | |
| depends_on: | |
| - backend | |
| - redis | |
| celery_beat: | |
| build: | |
| context: ./backend | |
| dockerfile: Dockerfile | |
| container_name: gmail2_celery_beat_prod | |
| restart: always | |
| command: celery -A app.tasks.celery_app.celery_app beat --loglevel=info | |
| env_file: | |
| - .env | |
| environment: | |
| - DATABASE_URL=postgresql+asyncpg://postgres:postgres@postgres:5432/gmail2 | |
| - MONGODB_URI=mongodb://mongodb:27017/ | |
| - REDIS_HOST=redis | |
| - REDIS_PORT=6379 | |
| depends_on: | |
| - backend | |
| - redis | |
| frontend: | |
| build: | |
| context: ./frontend | |
| dockerfile: Dockerfile | |
| args: | |
| - NEXT_PUBLIC_API_URL=http://localhost:8000 | |
| - NEXT_PUBLIC_WS_URL=ws://localhost:8000 | |
| container_name: gmail2_frontend_prod | |
| restart: always | |
| ports: | |
| - "3000:3000" | |
| depends_on: | |
| - backend | |
| prometheus: | |
| image: prom/prometheus:latest | |
| container_name: gmail2_prometheus_prod | |
| restart: always | |
| volumes: | |
| - ./prometheus.yml:/etc/prometheus/prometheus.yml | |
| ports: | |
| - "9090:9090" | |
| depends_on: | |
| - backend | |
| grafana: | |
| image: grafana/grafana:latest | |
| container_name: gmail2_grafana_prod | |
| restart: always | |
| ports: | |
| - "3001:3000" | |
| depends_on: | |
| - prometheus | |
| volumes: | |
| - grafanadata:/var/lib/grafana | |
| volumes: | |
| pgdata: | |
| mongodata: | |
| grafanadata: | |