forked from bbd-miniconomy-life-insurance/life-insurance
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
28 lines (27 loc) · 720 Bytes
/
docker-compose.yml
File metadata and controls
28 lines (27 loc) · 720 Bytes
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
version: '3.8'
services:
# DB
postgres:
image: postgres:alpine
container_name: postgres_db
restart: always
user: postgres
ports:
- 5432:5432
environment:
POSTGRES_DB: miniconomy
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
healthcheck:
test: ["CMD-SHELL", "pg_isready -d miniconomy -U postgres"]
interval: 10s
timeout: 5s
retries: 3
flyway:
image: flyway/flyway
command: -url=jdbc:postgresql://postgres:5432/miniconomy -schemas=public -user=postgres -password=postgres -locations=filesystem:/flyway/sql migrate
volumes:
- ./database:/flyway/sql
depends_on:
postgres:
condition: service_healthy