-
Notifications
You must be signed in to change notification settings - Fork 1
/
compose.yml
53 lines (51 loc) · 1.03 KB
/
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
version: "3.1"
services:
db:
image: postgres:15.4
container_name: postgres_container
environment:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: ${BX_STORAGE_SETTINGS__PASSWORD}
POSTGRES_DB: postgres
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres"]
interval: 10s
timeout: 5s
retries: 5
ports:
- "5432:5432"
volumes:
- postgres_data:/var/lib/postgresql/data
app:
depends_on:
db:
condition: service_healthy
build:
args:
- ENVIRONMENT=dev
context: ./
dockerfile: ./api/Dockerfile.dev
env_file:
- .env
ports:
- "8000:8000"
develop:
watch:
- action: rebuild
path: ./
target: /app
migrate:
depends_on:
db:
condition: service_healthy
build:
args:
- ENVIRONMENT=dev
context: ./
dockerfile: ./migrate/Dockerfile.dev
environment:
- WAIT_HOSTS=db:5432
env_file:
- .env
volumes:
postgres_data: