-
Notifications
You must be signed in to change notification settings - Fork 4
/
compose.yaml
63 lines (60 loc) · 1.33 KB
/
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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
name: nfce
services:
api:
build:
context: .
restart: always
expose:
- 80
volumes:
- ./src:/app
ports:
- 8000:80
depends_on:
- db
links:
- db
command: ["uvicorn", "drivers.rest.main:app", "--host", "0.0.0.0", "--port", "80", "--reload"]
environment:
DATABASE_HOSTNAME: db
DATABASE_USERNAME: ${DATABASE_USERNAME}
DATABASE_PASSWORD: ${DATABASE_PASSWORD}
DATABASE_NAME: ${DATABASE_NAME}
# telegram_bot:
# build:
# context: .
# restart: always
# expose:
# - 80
# volumes:
# - ./src:/app
# ports:
# - 5002:80
# depends_on:
# - db
# links:
# - db
# command: ["python", "-m", "drivers.bots.telegram"]
# environment:
# TELEGRAM_BOT_TOKEN: ${TELEGRAM_BOT_TOKEN}
# POSTGRES_HOST: db
# DATABASE_USERNAME: ${DATABASE_USERNAME}
# DATABASE_PASSWORD: ${DATABASE_PASSWORD}
# DATABASE_NAME: ${DATABASE_NAME}
db:
image: postgres
restart: always
shm_size: 128mb
expose:
- 5432
ports:
- 5432:5432
volumes:
- database_data:/var/lib/postgresql/data
environment:
POSTGRES_USER: ${DATABASE_USERNAME}
POSTGRES_PASSWORD: ${DATABASE_PASSWORD}
POSTGRES_DB: ${DATABASE_NAME}
volumes:
database_data:
driver: local