-
Notifications
You must be signed in to change notification settings - Fork 18
/
Copy pathdocker-compose.yml
75 lines (74 loc) · 1.85 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
version: '3.7'
services:
web:
build:
context: .
dockerfile: Dockerfile-env
ports:
- 5000:5000
env_file:
- ./.env
hostname: web
privileged: true
volumes:
- ".:/usr/src/app/"
- "./saml:/usr/src/app/turnpike/saml"
- "./dev-backends.yml:/etc/turnpike/backends.yml"
- "./dev-config.py:/etc/turnpike/dev-config.py"
networks:
mynet:
aliases:
- web.svc.cluster.local
environment:
TURNPIKE_CONFIG: /etc/turnpike/dev-config.py
nginx:
build:
context: ./nginx
dockerfile: Dockerfile
ports:
- 443:8443
depends_on:
- web
hostname: nginx
volumes:
- "./dev-backends.yml:/etc/turnpike/backends.yml"
- "./nginx/certs:/etc/nginx/certs"
networks:
mynet:
aliases:
- nginx.svc.cluster.local
environment:
NGINX_LISTEN: 8443 ssl
NGINX_SERVER_NAME: ${SERVER_NAME}
FLASK_SERVICE_URL: http://web.svc.cluster.local:5000
FLASK_SERVER_NAME: ${SERVER_NAME}
NGINX_SSL_CONFIG: |
ssl_certificate certs/cert.pem;
ssl_certificate_key certs/key.pem;
ssl_verify_client optional;
ssl_verify_depth 3;
ssl_client_certificate certs/ca.pem;
if (${_dollarhack:-$}ssl_client_verify = "SUCCESS") {
set ${_dollarhack:-$}http_x_rh_certauth_subject /${_dollarhack:-$}ssl_client_s_dn;
set ${_dollarhack:-$}http_x_rh_certauth_issuer /${_dollarhack:-$}ssl_client_i_dn;
}
redis:
image: redis:6
hostname: redis
networks:
mynet:
aliases:
- redis.svc.cluster.local
echo-server:
image: jmalloc/echo-server:latest
hostname: echo-server
ports:
- 8080:8080
networks:
mynet:
aliases:
- echo-server.svc.cluster.local
environment:
PORT: 8080
networks:
mynet: