-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
42 lines (42 loc) · 990 Bytes
/
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
version: "3.9"
services:
app:
env_file: .env
build:
context: .
dockerfile: build/app/Dockerfile
container_name: auth-id-app
ports:
- "9090:9090"
depends_on:
- postgres-master
volumes:
- ./.env:/go/auth-id/.env
networks:
- services
postgres-master:
env_file: .env
image: postgres:15
container_name: auth-id-postgres
environment:
POSTGRES_HOST: ${POSTGRES_HOST}
POSTGRES_DB: ${POSTGRES_DB}
POSTGRES_USER: ${POSTGRES_USER}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
POSTGRES_PORT: ${POSTGRES_PORT}
volumes:
- ../auth-id-postgres-data:/var/lib/postgresql/data
- ./migration:/opt/migration
ports:
- "5432:5432"
healthcheck:
test: [ "CMD-SHELL", "pg_isready -U ${POSTGRES_USER} -d ${POSTGRES_DB}" ]
interval: 10s
timeout: 5s
retries: 5
start_period: 10s
networks:
- services
networks:
services:
driver: bridge