-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathdocker-compose.yml
executable file
·95 lines (93 loc) · 2.42 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
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
version: '3.5'
services:
range_api:
depends_on:
- db
- minio
image: ${PROJECT}-${ENVIRONMENT}-api-img
container_name: ${PROJECT}-${ENVIRONMENT}-api
build:
context: ./
dockerfile: dev.Dockerfile
ports:
- ${API_PORT}:${API_PORT}
- 9229:9229
volumes:
- ./src:/home/nodejs/app/src
- ./scripts:/home/nodejs/app/scripts
- ./__tests__:/home/nodejs/app/__tests__
- ./__testHelpers__:/home/nodejs/app/__testHelpers__
environment:
- PORT=${API_PORT}
- POSTGRESQL_DATABASE=${POSTGRESQL_DATABASE}
- POSTGRESQL_USER=${POSTGRESQL_USER}
- POSTGRESQL_PASSWORD=${POSTGRESQL_PASSWORD}
- POSTGRESQL_HOST=db
- NODE_ENV=${ENVIRONMENT}
- POSTGRESQL_PORT=${POSTGRESQL_PORT}
- MINIO_ENDPOINT=minio
- MINIO_PUBLIC_ENDPOINT=127.0.0.1
- MINIO_PORT=9000
- MINIO_ACCESS_KEY=minio
- MINIO_SECRET_KEY=secretminiokey123
- MINIO_BUCKET=myra-dev
- NODE_ENV=production
- SSO_URL=https://dev.loginproxy.gov.bc.ca/auth/realms/standard/protocol/openid-connect
networks:
- local
db:
image: ${PROJECT}-${ENVIRONMENT}-postgress-img
container_name: ${PROJECT}-${ENVIRONMENT}-db
build:
context: ./services/db
dockerfile: Dockerfile
args:
- PORT:${POSTGRESQL_PORT}
ports:
- 5431:5432
environment:
- POSTGRES_USER=${POSTGRESQL_USER}
- POSTGRES_PASSWORD=${POSTGRESQL_PASSWORD}
- POSTGRES_DB=${POSTGRESQL_DATABASE}
networks:
- local
volumes:
- postgres:/var/lib/postgresql/data
minio:
image: minio/minio
volumes:
- minio-data:/data/minio
ports:
- 9000:9000
- 9001:9001
environment:
MINIO_ACCESS_KEY: minio
MINIO_SECRET_KEY: secretminiokey123
MINIO_DOMAIN: localhost
command: server /data/minio --console-address ":9001"
healthcheck:
test: ['CMD', 'curl', '-f', 'http://localhost:9000/minio/health/live']
interval: 30s
timeout: 20s
retries: 3
networks:
- local
# minio-nginx:
# image: nginx
# volumes:
# - ./nginx.conf:/etc/nginx/nginx.conf
# ports:
# - 9000:9000
# depends_on:
# - minio
# networks:
# - local
networks:
local:
driver: bridge
name: ${PROJECT}-${ENVIRONMENT}-network
volumes:
postgres:
name: ${PROJECT}-${ENVIRONMENT}-vol-postgres
minio-data:
name: minio-data-dev