-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathdocker-compose.prod.yml
102 lines (98 loc) · 3.73 KB
/
docker-compose.prod.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
version: "3.7"
services:
backend_api:
image: '${CI_REGISTRY_IMAGE}/api:latest'
container_name: backend-api
build:
context: ./backend
dockerfile: Dockerfile
environment:
- ENV=${ENV}
- PORT=${PORT}
- DB_USER=${DB_USER}
- DB_PASSWORD=${DB_PASSWORD}
- DB_HOST=${DB_HOST}
- DB_NAME=${DB_NAME}
- DBPORT=${DBPORT}
- DEFAULT_ADMIN_PASSWORD=${DEFAULT_ADMIN_PASSWORD}
- DEFAULT_USER_PASSWORD=${DEFAULT_USER_PASSWORD}
- AUTH_JWT_SECRET=${AUTH_JWT_SECRET}
- PUBLIC_API_KEY_TOKEN=${PUBLIC_API_KEY_TOKEN}
- USER_API_KEY_TOKEN=${USER_API_KEY_TOKEN}
- ADMIN_API_KEY_TOKEN=${ADMIN_API_KEY_TOKEN}
- SELLER_API_KEY_TOKEN=${SELLER_API_KEY_TOKEN}
- PAYPAL_ACCESS_TOKEN=${PAYPAL_ACCESS_TOKEN}
- STRIPE_SECRET_KEY=${STRIPE_SECRET_KEY}
- STRIPE_PUBLISHABLE_KEY=${STRIPE_PUBLISHABLE_KEY}
deploy:
placement:
constraints:
- node.role == worker
labels:
- traefik.enable=true
- traefik.docker.network=traefik-public
- traefik.constraint-label=traefik-public
- traefik.http.routers.api-http.rule=Host(`api.kod3rsstore.com`)
- traefik.http.routers.api-http.entrypoints=http
- traefik.http.routers.api-http.middlewares=https-redirect
- traefik.http.routers.api-https.rule=Host(`api.kod3rsstore.com`)
- traefik.http.routers.api-https.entrypoints=https
- traefik.http.routers.api-https.tls=true
- traefik.http.routers.api-https.tls.certresolver=le
- traefik.http.services.api.loadbalancer.server.port=2000
networks:
- default
- traefik-public
developers:
image: '${CI_REGISTRY_IMAGE}/developers:latest'
container_name: developers
build:
context: ./developerDocumentation
dockerfile: Dockerfile
deploy:
placement:
constraints:
- node.role == worker
labels:
- traefik.enable=true
- traefik.docker.network=traefik-public
- traefik.constraint-label=traefik-public
- traefik.http.routers.developers-http.rule=Host(`developers.kod3rsstore.com`)
- traefik.http.routers.developers-http.entrypoints=http
- traefik.http.routers.developers-http.middlewares=https-redirect
- traefik.http.routers.developers-https.rule=Host(`developers.kod3rsstore.com`)
- traefik.http.routers.developers-https.entrypoints=https
- traefik.http.routers.developers-https.tls=true
- traefik.http.routers.developers-https.tls.certresolver=le
- traefik.http.services.developers.loadbalancer.server.port=4000
networks:
- default
- traefik-public
internal:
image: '${CI_REGISTRY_IMAGE}/internal:latest'
container_name: internal
build:
context: ./internaldocs
dockerfile: Dockerfile
deploy:
placement:
constraints:
- node.role == worker
labels:
- traefik.enable=true
- traefik.docker.network=traefik-public
- traefik.constraint-label=traefik-public
- traefik.http.routers.internal-http.rule=Host(`internal.kod3rsstore.com`)
- traefik.http.routers.internal-http.entrypoints=http
- traefik.http.routers.internal-http.middlewares=https-redirect
- traefik.http.routers.internal-https.rule=Host(`internal.kod3rsstore.com`)
- traefik.http.routers.internal-https.entrypoints=https
- traefik.http.routers.internal-https.tls=true
- traefik.http.routers.internal-https.tls.certresolver=le
- traefik.http.services.internal.loadbalancer.server.port=5000
networks:
- default
- traefik-public
networks:
traefik-public:
external: true