-
Notifications
You must be signed in to change notification settings - Fork 2
/
docker-compose.yml
281 lines (265 loc) · 8.17 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
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
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
services:
node:
image: node:18-alpine
volumes:
- .:/data/
working_dir: /data
ui:
build: .
volumes:
- .:/data/
command: npm run serve
# command: npm run serve:prod
ports:
- '8000:8000'
depends_on:
- api
api:
image: silintl/idp-pw-api:7.0
platform: linux/amd64
ports:
- '8080:80'
depends_on:
- profileDb
- broker
- zxcvbn
- idp
env_file:
- ./.env.local
environment:
MYSQL_HOST: 'profileDb'
MYSQL_DATABASE: 'profile'
MYSQL_USER: 'user'
MYSQL_PASSWORD: 'pass'
EMAILER_CLASS: \tests\mock\emailer\FakeEmailer
EMAIL_SERVICE_baseUrl: 'dummy'
EMAIL_SERVICE_accessToken: 'dummy'
EMAIL_SERVICE_assertValidIp: 'false'
ALERTS_EMAIL_ENABLED: 'false'
HELP_CENTER_URL: 'https://example.org/help-center'
FROM_NAME: 'Tech support'
SUPPORT_PHONE: '007-867-5309'
SUPPORT_EMAIL: '[email protected]'
SUPPORT_URL: 'https://www.example.org/support'
SUPPORT_FEEDBACK: 'https://www.example.org/support-feedback'
UI_URL: 'https://profile.gtis.guru/#'
UI_CORS_ORIGIN: 'https://profile.gtis.guru'
ACCESS_TOKEN_HASH_KEY: 'KEY4TESTING'
ZXCVBN_API_BASEURL: 'http://zxcvbn:3000'
ID_BROKER_baseUrl: 'http://broker'
ID_BROKER_accessToken: 'local-testing-abc123'
ID_BROKER_assertValidBrokerIp: 'false'
AUTH_SAML_signRequest: 'false'
AUTH_SAML_checkResponseSigning: 'false'
AUTH_SAML_requireEncryptedAssertion: 'false'
AUTH_SAML_idpCertificate: ''
AUTH_SAML_spCertificate: ''
AUTH_SAML_spPrivateKey: ''
AUTH_SAML_entityId: 'profile-api.gtis.guru'
AUTH_SAML_ssoUrl: 'http://idp.gtis.guru/saml2/idp/SSOService.php'
AUTH_SAML_sloUrl: 'http://idp.gtis.guru/saml2/idp/SingleLogoutService.php'
PASSWORD_RULE_minLength: '10'
PASSWORD_RULE_maxLength: '255'
PASSWORD_RULE_minScore: '3'
command: ['bash', '-c', 'whenavail profileDb 3306 60 ./yii migrate --interactive=0 && ./run.sh']
profileDb:
image: mariadb:10
ports:
- '3306'
environment:
MYSQL_ROOT_PASSWORD: 'r00tp@ss!'
MYSQL_DATABASE: 'profile'
MYSQL_USER: 'user'
MYSQL_PASSWORD: 'pass'
profilePhpmyadmin:
image: phpmyadmin:5
ports:
- '8081:80'
depends_on:
- profileDb
environment:
PMA_HOST: 'profileDb'
PMA_USER: 'user'
PMA_PASSWORD: 'pass'
zxcvbn:
image: wcjr/zxcvbn-api
platform: linux/amd64
ports:
- '3000'
proxy:
# https://github.com/silinternational/traefik-https-proxy
image: silintl/traefik-https-proxy:1
platform: linux/amd64
ports:
- '80:80'
- '443:443'
depends_on:
- ui
- api
volumes:
- ./development/cert:/cert
env_file:
- ./.env.local
environment:
DNS_PROVIDER: 'cloudflare'
LETS_ENCRYPT_CA: 'staging'
TLD: 'gtis.guru'
SANS: 'profile.gtis.guru,profile-api.gtis.guru,idp.gtis.guru'
FRONTEND1_DOMAIN: 'profile.gtis.guru'
FRONTEND2_DOMAIN: 'profile-api.gtis.guru'
FRONTEND3_DOMAIN: 'idp.gtis.guru'
BACKEND1_URL: 'http://ui:8000'
BACKEND2_URL: 'http://api:80'
BACKEND3_URL: 'http://idp:80'
broker:
image: silintl/idp-id-broker:6
platform: linux/amd64
volumes:
- ./development/m991231_235959_insert_test_users.php:/data/console/migrations/m991231_235959_insert_test_users.php
ports:
- '8090:80'
depends_on:
- brokerDb
env_file:
- ./.env.local
environment:
APP_ENV: 'dev'
API_ACCESS_KEYS: 'local-testing-abc123'
MIGRATE_PW_FROM_LDAP: 'false'
MYSQL_HOST: 'brokerDb'
MYSQL_DATABASE: 'broker'
MYSQL_USER: 'user'
MYSQL_PASSWORD: 'pass'
EMAILER_CLASS: Sil\SilIdBroker\Behat\Context\fakes\FakeEmailer
EMAIL_SERVICE_baseUrl: 'dummy'
EMAIL_SERVICE_accessToken: 'dummy'
EMAIL_SERVICE_assertValidIp: 'false'
EMAIL_SIGNATURE: 'one red pill, please'
SUPPORT_EMAIL: '[email protected]'
HELP_CENTER_URL: 'https://example.org/help'
PASSWORD_FORGOT_URL: 'https://example.org/forgot'
PASSWORD_PROFILE_URL: 'https://example.org/profile'
MFA_WEBAUTHN_apiBaseUrl: mfaapi:8080/
# These are tied to similar values in dynamorestart/DynamoRestart.php
MFA_WEBAUTHN_apiKey: 10345678-1234-1234-1234-123456789012
MFA_WEBAUTHN_apiSecret: 11345678-1234-1234-1234-12345678
MFA_WEBAUTHN_appId: https://profile.gtis.guru/
MFA_WEBAUTHN_rpDisplayName: 'Local Development IDP'
MFA_WEBAUTHN_rpId: gtis.guru
command: ['bash', '-c', 'whenavail brokerDb 3306 60 ./yii migrate --interactive=0 && ./run.sh']
brokerDb:
image: mariadb:10
ports:
- '3306'
environment:
MYSQL_ROOT_PASSWORD: 'r00tp@ss!'
MYSQL_DATABASE: 'broker'
MYSQL_USER: 'user'
MYSQL_PASSWORD: 'pass'
brokerPhpmyadmin:
image: phpmyadmin:5
ports:
- '8091:80'
depends_on:
- brokerDb
environment:
PMA_HOST: 'brokerDb'
PMA_USER: 'user'
PMA_PASSWORD: 'pass'
idp:
image: silintl/ssp-base:10.1
platform: linux/amd64
volumes:
- ./development/authsources.php:/data/vendor/simplesamlphp/simplesamlphp/config/authsources.php
- ./development/saml20-idp-hosted.php:/data/vendor/simplesamlphp/simplesamlphp/metadata/saml20-idp-hosted.php
- ./development/saml20-sp-remote.php:/data/vendor/simplesamlphp/simplesamlphp/metadata/saml20-sp-remote.php
# - ./development/php-debugging.ini:/etc/php/7.0/apache2/php.ini
- ./development/default-logo.png:/data/vendor/simplesamlphp/simplesamlphp/www/logo.png
ports:
- '8088:80'
depends_on:
- silAuthDb
- broker
env_file:
- ./.env.local
environment:
ADMIN_PASS: 'a'
BASE_URL_PATH: 'https://idp.gtis.guru'
SECURE_COOKIE: 'false'
SHOW_SAML_ERRORS: 'true'
ADMIN_PROTECT_INDEX_PAGE: 'false'
THEME_USE: 'material:material'
ADMIN_EMAIL: '[email protected]'
SECRET_SALT: 'NlFalr5Faa73coPUFPP78BCi2ZUYhL+qVCOuJ466Bh4='
IDP_DOMAIN_NAME: 'idp.gtis.guru'
MFA_SETUP_URL: 'https://example.org/mfa-setup'
MFA_LEARN_MORE_URL: '//example.org/learn-more'
MYSQL_HOST: 'silAuthDb'
MYSQL_DATABASE: 'silauth'
MYSQL_USER: 'user'
MYSQL_PASSWORD: 'pass'
ID_BROKER_BASE_URI: 'http://broker'
ID_BROKER_ACCESS_TOKEN: 'local-testing-abc123'
ID_BROKER_ASSERT_VALID_IP: 'false'
REMEMBER_ME_SECRET: 'dummy'
PASSWORD_CHANGE_URL: 'https://profile.gtis.guru/#/password/create'
PASSWORD_FORGOT_URL: 'https://profile.gtis.guru/#/password/forgot'
PROFILE_URL: 'https://profile.gtis.guru/#'
TRUSTED_URL_DOMAINS: profile.gtis.guru
command: ['bash', '-c', 'whenavail silAuthDb 3306 60 ./run-idp.sh']
silAuthDb:
image: mariadb:10
ports:
- '3306'
environment:
MYSQL_ROOT_PASSWORD: 'r00tp@ss!'
MYSQL_DATABASE: 'silauth'
MYSQL_USER: 'user'
MYSQL_PASSWORD: 'pass'
dynamorestart:
build: ./dynamorestart
ports:
- 8080
volumes:
- ./dynamorestart/:/dynamo
environment:
AWS_ENDPOINT: dynamo:8000
AWS_DEFAULT_REGION: us-east-1
AWS_ACCESS_KEY_ID: abc123
AWS_SECRET_ACCESS_KEY: abc123
AWS_DISABLE_SSL: 'true'
API_KEY_TABLE: ApiKey
WEBAUTHN_TABLE: WebAuthn
depends_on:
- dynamo
working_dir: /dynamo
command: bash -c "composer update && php restart.php"
dynamo:
image: amazon/dynamodb-local:latest
platform: linux/amd64
ports:
- '8010:8000'
environment:
AWS_ACCESS_KEY_ID: abc123
AWS_SECRET_ACCESS_KEY: abc123
AWS_DEFAULT_REGION: us-east-1
command: '-jar DynamoDBLocal.jar -sharedDb'
mfaapi:
build: ./serverless-mfa-api
ports:
- 8080
volumes:
- ./serverless-mfa-api/override:/src/override
environment:
AWS_ENDPOINT: dynamo:8000
AWS_DEFAULT_REGION: us-east-1
AWS_ACCESS_KEY_ID: abc123
AWS_SECRET_ACCESS_KEY: abc123
AWS_DISABLE_SSL: 'true'
API_KEY_TABLE: ApiKey
WEBAUTHN_TABLE: WebAuthn
depends_on:
- dynamo
- dynamorestart
working_dir: /src
command: bash -c "go run ./server/"