-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.yml
45 lines (45 loc) · 1.43 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
version: '3'
services:
mysql:
image: mysql:8.0.24
container_name: mysql
environment:
MYSQL_ROOT_PASSWORD: password
MYSQL_DATABASE: rada
volumes:
- ./docker/mysql/data:/var/lib/mysql
- ./docker/mysql/my.cnf:/etc/mysql/conf.d/my.cnf
ports:
- 3306:3306
minio:
image: minio/minio:RELEASE.2022-01-08T03-11-54Z
container_name: minio
environment:
- MINIO_ROOT_USER=miniolocal
- MINIO_ROOT_PASSWORD=radalocal
- MINIO_REGION_NAME=us-east-1
entrypoint: sh
command: -c "
/opt/bin/minio server --console-address :9001 /mnt/data{1...8};"
volumes:
- ./docker/minio/:/mnt
ports:
- 9000:9000
- 9001:9001
setupminio:
image: minio/mc:RELEASE.2022-01-07T06-01-38Z
depends_on:
- minio
entrypoint: sh
command: -c "
until (/usr/bin/mc config host add rada http://minio:9000 miniolocal radalocal) do echo '...waiting...' && sleep 1; done;
/usr/bin/mc mb rada/contents;
/usr/bin/mc admin user add rada weak_authority_user weak_authority_user;
/usr/bin/mc admin user add rada rada_server rada_server;
/usr/bin/mc admin policy add rada/ policy_rada_server /mnt/policies/rada_server.json;
/usr/bin/mc admin policy set rada/ policy_rada_server user=rada_server;
/usr/bin/mc policy set-json /mnt/policies/contents_public.json rada/contents;
exit 0;
"
volumes:
- ./docker/minio/:/mnt