-
Notifications
You must be signed in to change notification settings - Fork 0
/
Docker-compose.yaml
241 lines (226 loc) · 5.13 KB
/
Docker-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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
version: '3'
services:
cadvisor:
image: gcr.io/cadvisor/cadvisor:v0.45.0
volumes:
- /:/rootfs:ro
- /var/run:/var/run:rw
- /sys:/sys:ro
- /var/lib/docker:/var/lib/docker:ro
- /var/run/docker.sock:/var/run/docker.sock:ro
networks:
- monitor-net
labels:
- prometheus-job=cadvisor
command:
- '-docker_only'
deploy:
mode: global
graphana:
image: graphana-oss-meetme
networks:
- monitor-net
deploy:
mode: replicated
replicas: 1
placement:
constraints:
- node.role == manager
prometheus:
image: prometheus-oss-meetme
extra_hosts:
- 'host.docker.internal:host-gateway'
networks:
- mongo-net
- monitor-net
- socat-net
depends_on:
- nginx-docker
deploy:
mode: replicated
replicas: 1
placement:
constraints:
- node.role == manager
#graphana docs have these, but idk if we need them
#command:
# - '--config.file=/etc/prometheus/prometheus.yml'
# - '--storage.tsdb.path=/prometheus'
# - '--web.console.libraries=/etc/prometheus/console_libraries'
# - '--web.console.templates=/etc/prometheus/consoles'
# - '--web.enable-lifecycle'
node-exporter:
image: prom/node-exporter:latest
volumes:
- /proc:/host/proc:ro
- /sys:/host/sys:ro
- /:/rootfs:ro
command:
- '--path.procfs=/host/proc'
- '--path.rootfs=/rootfs'
- '--path.sysfs=/host/sys'
- '--collector.filesystem.mount-points-exclude=^/(sys|proc|dev|host|etc)($$|/)'
networks:
- monitor-net
deploy:
mode: global
nginx:
image: nginx-oss-meetme
ports:
- 80:80
- 443:443
networks:
- monitor-net
- no-internet
- authnet
depends_on:
- prometheus
- graphana
- saml
- backend
- socket
- mongo
- shibboleth
deploy:
mode: replicated
replicas: 1
nginx-docker:
image: nginx-oss-docker
volumes:
- /var/run/docker.sock:/var/run/docker.sock
networks:
- monitor-net
privileged: true
deploy:
mode: replicated
replicas: 1
placement:
constraints:
- node.role == manager
mongo:
image: database-meetme
networks:
- no-internet
- mongo-net
mongo-jr:
image: database-meetme
networks:
- no-internet
- mongo-net
depends_on:
- mongo
mongo-the-third:
image: database-meetme
networks:
- no-internet
- mongo-net
depends_on:
- mongo
mongoinit:
image: mongo # this container will exit after executing the command
restart: 'no'
depends_on:
- mongo
- mongo-jr
- mongo-the-third
networks:
- mongo-net
command: >
mongosh --host mongo:27017 --eval 'rs.initiate({
"_id" : "rs0",
"members" : [
{
"_id" : 0,
"host" : "mongo:27017",
"priority": 5
},
{
"_id" : 1,
"host" : "mongo-jr:27017",
"priority": 1
},
{
"_id" : 2,
"host" : "mongo-the-third:27017",
"priority": 1
}
]
});
'
backend:
image: backend-meetme
networks:
- no-internet
- authnet
- monitor-net
depends_on:
- mongoinit
deploy:
mode: replicated
replicas: 2
frontend:
image: frontend-meetme-webpack
networks:
- no-internet
- monitor-net
depends_on:
- mongoinit
volumes:
- ./frontend:/root
deploy:
mode: replicated
replicas: 1
socket:
image: websocket-meetme
networks:
- no-internet
- mongo-net
deploy:
mode: replicated
replicas: 1
openldap:
image: bitnami/openldap:2
environment:
- LDAP_ADMIN_USERNAME=admin
- LDAP_ADMIN_PASSWORD=adminpassword
- LDAP_USERS=netid1,netid2,netid3,netid4,netid5,netid6
- LDAP_PASSWORDS=rutgers1,rutgers2,rutgers3,rutgers4,rutgers5,rutgers6
- BITNAMI_DEBUG=true
networks:
- authnet
volumes:
- ./openldap_data:/bitnami/openldap
- ./ldaptest/eduPerson.ldif:/schema/custom.ldif
- ./ldaptest/bootstrap.ldif:/ldifs/bootstrap.ldif
shibboleth:
image: shibboleth-idp-meetme
networks:
- authnet
- no-internet
environment:
- JAVA_OPTS=-Djava.security.egd=file:/dev/urandom -Xmx3000m
ports:
- 4443:443
links:
- 'backend:api.localhost.edu'
saml:
image: kristophjunge/test-saml-idp
environment:
- SIMPLESAMLPHP_SP_ENTITY_ID=saml-poc
- SIMPLESAMLPHP_SP_ASSERTION_CONSUMER_SERVICE=https://api.localhost.edu/login
- SIMPLESAMLPHP_SP_SINGLE_LOGOUT_SERVICE=http://api.localhost.edu/logout
networks:
- authnet
volumes:
- ./saml/users.php:/var/www/simplesamlphp/config/authsources.php
networks:
no-internet:
driver: bridge
authnet:
driver: bridge
mongo-net:
driver: bridge
monitor-net:
driver: bridge
socat-net:
driver: bridge