-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
45 lines (41 loc) · 916 Bytes
/
docker-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
version: "3"
services:
service:
build:
context: .
dockerfile: Dockerfile
ports:
- "3000:3000"
- "3001:3001"
environment:
- FLASK_ENV=development
- FLASK_APP=service.server:app
- FLASK_RUN_HOST=0.0.0.0
- FLASK_RUN_PORT=3000
- FLASK_DEBUG=1
- LOG_LEVEL=DEBUG
- DATABASE_HOST=db
- DATABASE_PORT=5432
- DATABASE_DB=coding_challenge
- DATABASE_USER=noyo
- DATABASE_PASSWORD=noyo
working_dir: /usr/src/app
volumes:
- .:/usr/src/app
depends_on:
- db
links:
- db
db:
image: postgres:9.6-alpine
ports:
- "5432:5432"
environment:
- POSTGRES_DB=coding_challenge
- POSTGRES_USER=noyo
- POSTGRES_PASSWORD=noyo
volumes:
- db-data:/var/lib/postgresql/data
- ./schema.sql:/docker-entrypoint-initdb.d/init.sql
volumes:
db-data: