-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
69 lines (64 loc) · 1.75 KB
/
docker-compose.yml
File metadata and controls
69 lines (64 loc) · 1.75 KB
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
59
60
61
62
63
64
65
66
67
68
69
version: '3.7'
services:
minio:
image: minio/minio:latest
container_name: minio
ports:
- "9000:9000"
- "9001:9001"
command: server --console-address ":9001" /data/ --address ':9000'
environment:
- MINIO_ROOT_USER=${MINIO_USER}
- MINIO_ROOT_PASSWORD=${MINIO_PASSWORD}
volumes:
- minio_data:/data
healthcheck:
test: timeout 5s bash -c ':> /dev/tcp/127.0.0.1/9000' || exit 1
interval: 1s
timeout: 10s
retries: 5
restart: always
minio-create-bucket:
image: minio/mc
depends_on:
minio:
condition: service_healthy
command: >
mc alias set minio http://minio:9000 ${MINIO_USER} ${MINIO_PASSWORD}
mc mb --ignore-existing minio/mlflow
postgres:
image: postgres:latest
container_name: postgres
ports:
- "5432:5432"
environment:
- POSTGRES_USER=${POSTGRES_USER}
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
- POSTGRES_DB=mlflow
volumes:
- postgres_data:/var/lib/postgresql/data
restart: always
mlflow:
build: ./mlflow
image: mlflow
container_name: mlflow
depends_on: ["minio-create-bucket", "postgres"]
ports:
- "5000:5000"
environment:
- MLFLOW_S3_ENDPOINT_URL=http://minio:9000
- AWS_ACCESS_KEY_ID=${MINIO_USER}
- AWS_SECRET_ACCESS_KEY=${MINIO_PASSWORD}
- POSTGRES_USER=${POSTGRES_USER}
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
command: >
mlflow server
--host 0.0.0.0
--port 5000
--backend-store-uri postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@postgres:5432/mlflow
--artifacts-destination s3://mlflow
--gunicorn-opts "--log-level debug"
restart: always
volumes:
postgres_data:
minio_data: