-
Notifications
You must be signed in to change notification settings - Fork 22
/
Copy pathdocker-compose.basic-auth-ldap-test.yaml
101 lines (96 loc) · 3.05 KB
/
docker-compose.basic-auth-ldap-test.yaml
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
95
96
97
98
99
100
101
services:
minio:
container_name: minio-ldap-test
hostname: minio
image: minio/minio:${MINIO_VERSION}
entrypoint: sh
command: -c 'mkdir -p /data/mlflow && minio server /data --console-address ":9001"'
environment:
MINIO_ROOT_USER: minioadmin
MINIO_ROOT_PASSWORD: minioadmin
ports:
- "9000:9000"
- "9001:9001"
healthcheck:
test: ["CMD-SHELL", "curl -fsS http://localhost:9000/minio/health/live || exit 1"]
interval: 5s
timeout: 10s
retries: 3
start_period: 5s
networks:
- basic_auth_ldap_test_nw
lldap:
image: lldap/lldap:${LLDAP_VERSION}
hostname: lldap
container_name: lldap-ldap-test
ports:
- "3890:3890"
- "17170:17170"
environment:
LLDAP_LDAP_USER_DN: admin
LLDAP_LDAP_USER_PASS: admin123
LLDAP_LDAP_BASE_DN: dc=mlflow,dc=test
networks:
- basic_auth_ldap_test_nw
lldap-bootstrap:
container_name: lldap-bootstrap-ldap-test
hostname: lldapboot
image: lldap/lldap:${LLDAP_VERSION}
entrypoint: sh -c './bootstrap.sh; tail -f /dev/null'
environment:
LLDAP_URL: http://lldap:17170
LLDAP_ADMIN_USERNAME: admin
LLDAP_ADMIN_PASSWORD: admin123
DO_CLEANUP: true
volumes:
- ./test-containers/basic-auth/ldap/group:/group-configs:ro
- ./test-containers/basic-auth/ldap/user:/user-configs:ro
networks:
- basic_auth_ldap_test_nw
depends_on:
lldap:
condition: service_healthy
healthcheck:
test: ["CMD-SHELL", "exit 0"]
interval: 1s
timeout: 1s
retries: 1
mlflow:
container_name: mlflow-basic-auth-ldap-test
build:
context: .
dockerfile: Dockerfile
command: "mlflow server --backend-store-uri sqlite:///db.sqlite --default-artifact-root=s3://mlflow/ --host=0.0.0.0 --port=8080 --workers 4 --gunicorn-opts='--timeout=120 --log-level=debug' --app-name basic-auth"
environment:
MLFLOW_FLASK_SERVER_SECRET_KEY: 0123456789
MLFLOW_S3_ENDPOINT_URL: http://minio:9000
AWS_ACCESS_KEY_ID: minioadmin
AWS_SECRET_ACCESS_KEY: minioadmin
MLFLOW_AUTH_CONFIG_PATH: /mlflow/basic_auth.ini
ALEMBIC_LOG_LEVEL: DEBUG
FLASK_ENV: development
DEBUG: True
LDAP_URI: ldap://lldap:3890/dc=mlflow,dc=test
LDAP_LOOKUP_BIND: uid=%s,ou=people,dc=mlflow,dc=test
LDAP_GROUP_ATTRIBUTE: dn
LDAP_GROUP_SEARCH_BASE_DN: ou=groups,dc=mlflow,dc=test
LDAP_GROUP_SEARCH_FILTER: (&(objectclass=groupOfUniqueNames)(uniquemember=%s))
LDAP_GROUP_USER_DN: cn=test-user,ou=groups,dc=mlflow,dc=test
LDAP_GROUP_ADMIN_DN: cn=test-admin,ou=groups,dc=mlflow,dc=test
restart: always
ports:
- "8080:8080"
networks:
- basic_auth_ldap_test_nw
volumes:
- ./test-containers/basic-auth/ldap/basic_auth.ini:/mlflow/basic_auth.ini
depends_on:
minio:
condition: service_healthy
lldap:
condition: service_healthy
lldap-bootstrap:
condition: service_healthy
networks:
basic_auth_ldap_test_nw:
driver: bridge