Spaces:
Sleeping
Sleeping
File size: 1,451 Bytes
ed8ccc7 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 | # docker-compose.yml
services:
postgres:
image: postgres:15-alpine
container_name: sentinel_postgres
environment:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: sentinel_db
ports:
- "5432:5432"
volumes:
- sentinel_postgres_data:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres -d sentinel_db"]
interval: 5s
timeout: 5s
retries: 5
mlflow:
image: ghcr.io/mlflow/mlflow:v2.11.1
container_name: sentinel_mlflow
ports:
- "5000:5000"
environment:
- MLFLOW_BACKEND_STORE_URI=sqlite:////mlflow.db
volumes:
- sentinel_mlflow_data:/mlflow
command: mlflow server --host 0.0.0.0 --port 5000 --backend-store-uri sqlite:////mlflow/mlflow.db --serve-artifacts --artifacts-destination /mlflow/artifacts --gunicorn-opts "--timeout 120"
backend:
build:
context: .
dockerfile: Dockerfile
container_name: sentinel_backend
ports:
- "8000:8000"
environment:
- DATABASE_URL=postgresql://postgres:postgres@sentinel_postgres:5432/sentinel_db
- MLFLOW_TRACKING_URI=http://sentinel_mlflow:5000
volumes:
- ./backend:/app
depends_on:
postgres:
condition: service_healthy
mlflow:
condition: service_started
volumes:
sentinel_postgres_data:
sentinel_mlflow_data:
networks:
default:
name: sentinel_net
|