-
Notifications
You must be signed in to change notification settings - Fork 129
/
docker-compose-mysql-minio.yml
58 lines (57 loc) · 1.58 KB
/
docker-compose-mysql-minio.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
version: '3'
services:
source-mysql:
image: mysql:8
restart: always
command: --default-authentication-plugin=mysql_native_password
healthcheck:
test: ['CMD', 'mysqladmin', 'ping', '-u', 'root', '--password=password']
timeout: 45s
interval: 10s
retries: 10
environment:
- MYSQL_ROOT_PASSWORD=password
volumes:
- ./db/mysql:/docker-entrypoint-initdb.d
ports:
- 3306:3306
dest-mysql:
image: mysql:8
restart: always
command: --default-authentication-plugin=mysql_native_password
healthcheck:
test: ['CMD', 'mysqladmin', 'ping', '-u', 'root', '--password=password']
timeout: 45s
interval: 10s
retries: 10
environment:
- MYSQL_ROOT_PASSWORD=password
ports:
- 3307:3306
bridge-minio:
image: minio/minio:RELEASE.2022-03-17T06-34-49Z
restart: always
command: server --console-address ":9001" /data/minio/
healthcheck:
test: ['CMD', 'curl', '-f', 'http://localhost:9000/minio/health/live']
interval: 30s
timeout: 20s
retries: 3
environment:
MINIO_ROOT_USER: minioadmin
MINIO_ROOT_PASSWORD: minioadmin
ports:
- 9000:9000
- 9001:9001
create-minio-bucket:
image: minio/mc
depends_on:
- bridge-minio
entrypoint: >
/bin/sh -c "
/usr/bin/mc config host add myminio http://bridge-minio:9000 minioadmin minioadmin;
/usr/bin/mc rm -r --force myminio/replibyte-test;
/usr/bin/mc mb myminio/replibyte-test;
/usr/bin/mc policy download myminio/replibyte-test;
exit 0;
"