-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
47 lines (45 loc) · 1.28 KB
/
docker-compose.yml
File metadata and controls
47 lines (45 loc) · 1.28 KB
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
services:
app:
build:
context: .
dockerfile: Dockerfile.dev
ports:
- "4000:4000"
environment:
MIX_ENV: ${MIX_ENV:-dev}
DATABASE_URL: ecto://${DATABASE_USERNAME:-postgres}:${DATABASE_PASSWORD:-postgres}@${DATABASE_HOST:-db}:${DATABASE_PORT:-5432}/${DATABASE_NAME:-slax_dev}
DATABASE_POOL_SIZE: ${DATABASE_POOL_SIZE:-10}
volumes:
- .:/app
- deps:/app/deps
- _build:/app/_build
depends_on:
db:
condition: service_healthy
db:
image: postgres:15-alpine
environment:
POSTGRES_USER: ${DATABASE_USERNAME:-postgres}
POSTGRES_PASSWORD: ${DATABASE_PASSWORD:-postgres}
POSTGRES_DB: ${DATABASE_NAME:-slax_dev}
PGDATA: /pgdata
ports:
- "5432:5432"
volumes:
- pgdata:/pgdata
healthcheck:
test:
[
"CMD-SHELL",
"pg_isready -U ${DATABASE_USERNAME:-postgres} -d ${DATABASE_NAME:-slax_dev}",
]
interval: 5s
timeout: 5s
retries: 5
volumes:
build:
deps:
node_modules:
pgdata:
static:
_build: