-
Notifications
You must be signed in to change notification settings - Fork 21
/
docker-compose.ci.yml
62 lines (57 loc) · 1.49 KB
/
docker-compose.ci.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
version: '3.5'
services:
django:
image: "${IMAGE_NAME}"
ports:
- 8000:8000
links:
- "postgres:postgres"
- "storage:storage"
- "createbuckets:createbuckets"
volumes:
- ./src/:/src/
- ./docs/:/src/docs/
- ./etc/:/src/etc/
- ./locale/:/src/locale/
- ./run.sh:/src/run.sh
- ./tasks.py:/src/tasks.py
env_file:
- .envs/.env
command: ./run.sh
postgres:
image: postgres:12.6
env_file:
- .envs/.env
command: postgres -c max_connections=10000
ports:
- "5432:5432"
volumes:
- postgres_data:/var/lib/postgresql/data
storage:
image: minio/minio:latest
ports:
- 9000:9000
- 9001:9001
volumes:
- storage:/storage
env_file:
- .envs/.env
command: server /storage --console-address ":9001"
createbuckets:
image: minio/mc
depends_on:
- storage
env_file:
- .envs/.env
entrypoint: >
/bin/sh -c "
until (/usr/bin/mc config host add myminio $${MINIO_S3_ENDPOINT_URL} $${MINIO_ROOT_USER} $${MINIO_ROOT_PASSWORD}) do echo '...waiting...' && sleep 1; done;
/usr/bin/mc mb myminio/$${AWS_STORAGE_BUCKET_NAME};
/usr/bin/mc policy set download myminio/$${AWS_STORAGE_BUCKET_NAME};
/usr/bin/mc admin user add myminio $${MINIO_USER_ACCESS_KEY} $${MINIO_USER_SECRET_KEY};
/usr/bin/mc admin policy set myminio readwrite user=$${MINIO_USER_ACCESS_KEY};
exit 0;
"
volumes:
postgres_data:
storage: