-
Notifications
You must be signed in to change notification settings - Fork 4k
/
docker-compose.yml
94 lines (89 loc) · 2.24 KB
/
docker-compose.yml
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
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
version: "3"
services:
minio:
image: minio/minio
expose:
- "9000"
ports:
- "9000:9000"
# MinIO Console is available at http://localhost:9001
- "9001:9001"
environment:
MINIO_ROOT_USER: "user"
MINIO_ROOT_PASSWORD: "password"
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:9000/minio/health/live"]
interval: 1s
timeout: 10s
retries: 5
# Note there is no bucket by default
command: server /data --console-address ":9001"
minio-create-bucket:
image: minio/mc
depends_on:
minio:
condition: service_healthy
entrypoint: >
bash -c "
mc alias set minio http://minio:9000 user password &&
if ! mc ls minio | grep --quiet bucket; then
mc mb minio/bucket
else
echo 'bucket already exists'
fi
"
artifacts-server:
build:
context: .
dockerfile: "${DOCKERFILE:-Dockerfile}"
depends_on:
- minio-create-bucket
expose:
- "5500"
ports:
- "5500:5500"
environment:
MLFLOW_S3_ENDPOINT_URL: http://minio:9000
AWS_ACCESS_KEY_ID: "user"
AWS_SECRET_ACCESS_KEY: "password"
command: >
mlflow server
--host 0.0.0.0
--port 5500
--artifacts-destination s3://bucket
--gunicorn-opts "--log-level debug"
--serve-artifacts-opt
postgres:
image: postgres
restart: always
environment:
POSTGRES_DB: db
POSTGRES_USER: user
POSTGRES_PASSWORD: password
tracking-server:
build:
context: .
dockerfile: "${DOCKERFILE:-Dockerfile}"
depends_on:
- postgres
- artifacts-server
expose:
- "5000"
ports:
# MLflow UI is available at http://localhost:5000
- "5000:5000"
command: >
mlflow server
--host 0.0.0.0
--port 5000
--backend-store-uri postgresql://user:password@postgres:5432/db
--default-artifact-root http://artifacts-server:5500/api/2.0/mlflow-artifacts/artifacts/experiments
--gunicorn-opts "--log-level debug"
client:
build:
context: .
dockerfile: "${DOCKERFILE:-Dockerfile}"
depends_on:
- tracking-server
environment:
MLFLOW_TRACKING_URI: http://tracking-server:5000