-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose-dev.yml
More file actions
75 lines (68 loc) · 1.92 KB
/
docker-compose-dev.yml
File metadata and controls
75 lines (68 loc) · 1.92 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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
version: '3.3'
services:
postgres:
container_name: todo_postgres
image: postgres:latest
environment:
POSTGRES_USER: ${DB_USERNAME:-todo}
POSTGRES_PASSWORD: ${DB_PASSWORD:-todo}
PGDATA: /data/postgres
volumes:
- postgres:/data/postgres
- ./DbScripts:/scripts
- ./DbScripts/migration.sql:/docker-entrypoint-initdb.d/migration.sql
ports:
- "5433:5432"
networks:
- todo_net
restart: unless-stopped
webapp:
container_name: todo_webapp
build:
context: .
dockerfile: ./WebApp/Dockerfile
ports:
- "8001:80"
depends_on:
- postgres
environment:
ASPNETCORE_ENVIRONMENT: ${ASPNETCORE_ENVIRONMENT:-Development}
DB_CONNECTION_STRING: "host=${DB_HOST:-todo_postgres};port=${DB_PORT:-5432};database=${DB_DATABASE:-todo};username=${DB_USERNAME:-todo};password=${DB_PASSWORD:-todo};"
networks:
- todo_net
restart: unless-stopped
webapi:
container_name: todo_webapi
build:
context: .
dockerfile: ./WebApi/Dockerfile
ports:
- "8002:80"
depends_on:
- postgres
environment:
ASPNETCORE_ENVIRONMENT: ${ASPNETCORE_ENVIRONMENT:-Development}
DB_CONNECTION_STRING: "host=${DB_HOST:-todo_postgres};port=${DB_PORT:-5432};database=${DB_DATABASE:-todo};username=${DB_USERNAME:-todo};password=${DB_PASSWORD:-todo};"
networks:
- todo_net
restart: unless-stopped
pgadmin:
container_name: todo_pgadmin
image: dpage/pgadmin4:latest
environment:
PGADMIN_DEFAULT_EMAIL: ${PGADMIN_DEFAULT_EMAIL:[email protected]}
PGADMIN_DEFAULT_PASSWORD: ${PGADMIN_DEFAULT_PASSWORD:-admin}
PGADMIN_CONFIG_SERVER_MODE: 'False'
volumes:
- pgadmin:/var/lib/pgadmin
ports:
- "${PGADMIN_PORT:-5051}:80"
networks:
- todo_net
restart: unless-stopped
networks:
todo_net:
driver: bridge
volumes:
postgres:
pgadmin: