-
-
Notifications
You must be signed in to change notification settings - Fork 16
/
compose.yaml
47 lines (44 loc) · 896 Bytes
/
compose.yaml
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
name: "pydolarvenezuela-api"
services:
web:
build: .
ports:
- "8000:8000"
depends_on:
- db
- redis
networks:
- app-network
volumes:
- .:/app
redis:
image: "redis:alpine"
container_name: redis
ports:
- "${REDIS_PORT}:6379"
command: redis-server --requirepass ${REDIS_PASSWORD}
networks:
- app-network
db:
image: "postgres:16-alpine3.20"
restart: always
container_name: db
hostname: db
ports:
- "${SQL_PORT}:5432"
environment:
TZ: ${TIMEZONE}
PGTZ: ${TIMEZONE}
POSTGRES_DB: ${SQL_DB_NAME}
POSTGRES_USER: ${SQL_USER}
POSTGRES_PASSWORD: ${SQL_PASSWORD}
healthcheck:
test: pg_isready -d ${SQL_DB_NAME} -U ${SQL_USER}
volumes:
- db:/var/lib/postgresql/data
networks:
- app-network
volumes:
db:
networks:
app-network: