-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.yml
79 lines (71 loc) · 1.97 KB
/
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
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
76
77
78
79
version: '3'
services:
db:
image: postgres
volumes:
- flask_db:/var/lib/postgresql/data
environment:
POSTGRES_PASSWORD: kdlsjfsdfds
POSTGRES_USER: db_admin
container_name: flask_db
flask:
env_file:
- debug_mode.env
build: ./dockerfiles/flask
command: python main.py
ports:
- 5000:5000
volumes:
- .:/code
links:
- guac:guac-server
restart: always
container_name: flask_app
init-guacamole-db:
image: guacamole/guacamole:1.0.0
command: ["/bin/sh", "-c", "test -e /init/initdb.sql && echo 'init file already exists' || /opt/guacamole/bin/initdb.sh --postgres > /init/initdb.sql" ]
volumes:
- dbinit:/init
container_name: init_guac
postgres:
image: postgres:latest
restart: unless-stopped
volumes:
- dbinit:/docker-entrypoint-initdb.d
- dbdata:/var/lib/postgresql/data
environment:
POSTGRES_USER: dbuser
POSTGRES_PASSWORD: dbpassword1234
depends_on:
- init-guacamole-db
container_name: guac_db
guacd:
image: guacamole/guacd:1.0.0
restart: unless-stopped
container_name: practicum_guacd_1
guac:
image: guacamole/guacamole:1.0.0
restart: unless-stopped
ports:
- 8080:8080
environment:
GUACD_HOSTNAME: guacd
POSTGRES_HOSTNAME: postgres
POSTGRES_DATABASE: dbuser
POSTGRES_USER: dbuser
POSTGRES_PASSWORD: dbpassword1234
depends_on:
- postgres
- guacd
container_name: guac_app
nameserver:
build: ./dockerfiles/nameserver
container_name: nameserver
ports:
- "9090:9090"
volumes:
dbinit:
driver: local
dbdata:
driver: local
flask_db: