Skip to content

Commit 01d5a06

Browse files
committed
Add deps to mlflow container
1 parent 392a38b commit 01d5a06

File tree

2 files changed

+21
-3
lines changed

2 files changed

+21
-3
lines changed

dev/mlflow.Dockerfile

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
FROM ghcr.io/mlflow/mlflow:v2.20.3
2+
3+
4+
# hadolint ignore=DL3013
5+
RUN pip install --no-cache-dir --upgrade pip \
6+
&& pip install --no-cache-dir boto3==1.37.11 psycopg2-binary==2.9.10

docker-compose.yml

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,14 +32,26 @@ services:
3232
- minio:/data
3333

3434
mlflow:
35-
image: ghcr.io/mlflow/mlflow:latest
35+
build:
36+
context: .
37+
dockerfile: ./dev/mlflow.Dockerfile
3638
ports:
3739
- "5000:5000"
3840
environment:
3941
- MLFLOW_S3_ENDPOINT_URL=http://minio:9000
40-
- AWS_ACCESS_KEY=${DJANGO_MINIO_STORAGE_ACCESS_KEY:-minioAccessKey}
42+
- AWS_ACCESS_KEY_ID=${DJANGO_MINIO_STORAGE_ACCESS_KEY:-minioAccessKey}
4143
- AWS_SECRET_ACCESS_KEY=${DJANGO_DATABASE_PASSWORD:-minioSecretKey}
42-
command: mlflow server --host 0.0.0.0 --port 5000 --backend-store-uri postgresql://postgres:postgres@postgres:5432/mlflow --artifacts-destination s3://bucket
44+
command: mlflow server --host 0.0.0.0 --port 5000 --backend-store-uri postgresql://postgres:postgres@postgres:5432/mlflow --artifacts-destination s3://mlflow --default-artifact-root s3://mlflow
45+
46+
# mlflow:
47+
# image: ghcr.io/mlflow/mlflow:latest
48+
# ports:
49+
# - "5000:5000"
50+
# environment:
51+
# - MLFLOW_S3_ENDPOINT_URL=http://minio:9000
52+
# - AWS_ACCESS_KEY_ID=${DJANGO_MINIO_STORAGE_ACCESS_KEY:-minioAccessKey}
53+
# - AWS_SECRET_ACCESS_KEY=${DJANGO_DATABASE_PASSWORD:-minioSecretKey}
54+
# command: bash -c "python3 -m pip install psycopg2-binary boto3 && mlflow server --host 0.0.0.0 --port 5000 --backend-store-uri postgresql://postgres:postgres@postgres:5432/mlflow --artifacts-destination s3://mlflow --default-artifact-root s3://mlflow"
4355

4456
volumes:
4557
postgres:

0 commit comments

Comments
 (0)