-
Notifications
You must be signed in to change notification settings - Fork 146
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
50 lines (48 loc) · 1.15 KB
/
docker-compose.yml
File metadata and controls
50 lines (48 loc) · 1.15 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
48
49
50
services:
app:
container_name: app
image: app
build:
context: .
dockerfile: Dockerfile
depends_on:
- postgres
networks:
- db_nw
- web_nw
ports:
- "8000:5000"
restart: unless-stopped
environment:
- SQLALCHEMY_DATABASE_URI=postgresql://${POSTGRES_USER:-db1}:${POSTGRES_PASSWORD:-db1}@${POSTGRES_HOST:-postgres}/${POSTGRES_DB:-db1}
- RESET_DB=${RESET_DB:-no}
- VERSION=${VERSION:-1.0.0}
- POSTGRES_USER=${POSTGRES_USER:-db1}
- POSTGRES_HOST=${POSTGRES_HOST:-postgres}
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD:-db1}
- POSTGRES_DB=${POSTGRES_DB:-db1}
- GUNICORN_WORKERS=2
#env_file:
# - .env
postgres:
container_name: postgres
image: postgres
environment:
POSTGRES_USER: ${POSTGRES_USER:-db1}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-db1}
POSTGRES_DB: ${POSTGRES_DB:-db1}
PGDATA: /data/postgres
#volumes:
# - postgres:/data/postgres
ports:
- "5432:5432"
networks:
- db_nw
restart: unless-stopped
networks:
db_nw:
driver: bridge
web_nw:
driver: bridge
volumes:
dbdata: