-
Notifications
You must be signed in to change notification settings - Fork 6
/
docker-compose.prod.yml
197 lines (185 loc) · 7.52 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
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
version: "4"
services:
gateway:
image: traefik:v2.7
ports:
- "80:80"
- "8080:8080"
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- ./traefik.yml:/etc/traefik/traefik.yml
identity-web:
image: doceazedo/ssn-identity-web:latest
pull_policy: always
labels:
- "traefik.enable=true"
- "traefik.http.routers.identity.entrypoints=web"
- "traefik.http.routers.identity.rule=Host(`id.${PUBLIC_BASE_DOMAIN}`)"
ports:
- "3000:3000"
environment:
PUBLIC_BASE_DOMAIN: ${PUBLIC_BASE_DOMAIN}
PUBLIC_WEBSITE_URL: ${PUBLIC_WEBSITE_URL}
PUBLIC_DASHBOARD_URL: ${PUBLIC_DASHBOARD_URL}
PUBLIC_IDENTITY_URL: ${PUBLIC_IDENTITY_URL}
PUBLIC_REGISTER_ENABLED: ${PUBLIC_REGISTER_ENABLED}
PUBLIC_REGISTER_INVITE_ONLY: ${PUBLIC_REGISTER_INVITE_ONLY}
PUBLIC_REGISTER_INVITES_PER_USER: ${PUBLIC_REGISTER_INVITES_PER_USER}
PUBLIC_DISCORD_CLIENT_ID: ${PUBLIC_DISCORD_CLIENT_ID}
PUBLIC_CF_TURNSTILE_SITE_KEY: ${PUBLIC_CF_TURNSTILE_SITE_KEY}
PUBLIC_RCON_URL: ${PUBLIC_RCON_URL}
DISCORD_CLIENT_SECRET: ${DISCORD_CLIENT_SECRET}
CATRACA_IDENTITY_TOKEN: ${CATRACA_IDENTITY_TOKEN}
DATABASE_URL: ${DATABASE_URL}
WH_DEFAULT_ADMIN_USERNAME: ${WH_DEFAULT_ADMIN_USERNAME}
CF_TURNSTILE_SECRET_KEY: ${CF_TURNSTILE_SECRET_KEY}
SENDGRID_API_KEY: ${SENDGRID_API_KEY}
SENDGRID_FROM: ${SENDGRID_FROM}
LOCAL_COMMANDER_URL: ${LOCAL_COMMANDER_URL}
COMMANDER_TOKEN: ${COMMANDER_TOKEN}
warehouse:
image: postgres:13.1-alpine
environment:
POSTGRES_USER: ${POSTGRES_USER}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
POSTGRES_DB: ${POSTGRES_DB}
volumes:
- ${MNT_WAREHOUSE}:/var/lib/postgresql/data
ports:
- "5432:5432"
warehouse-migrate:
image: doceazedo/ssn-warehouse-migrate:latest
pull_policy: always
depends_on:
- warehouse
restart: on-failure
environment:
DATABASE_URL: ${DATABASE_URL}
gatekeeper-web:
image: doceazedo/ssn-gatekeeper-web:latest
pull_policy: always
labels:
- "traefik.enable=true"
- "traefik.http.routers.gatekeeper.entrypoints=web"
- "traefik.http.routers.gatekeeper.rule=Host(`gk.${PUBLIC_BASE_DOMAIN}`)"
ports:
- "3001:3000"
environment:
PUBLIC_IDENTITY_URL: ${PUBLIC_IDENTITY_URL}
PUBLIC_GATEKEEPER_URL: ${PUBLIC_GATEKEEPER_URL}
GK_REDIS_URL: ${GK_REDIS_URL}
DATABASE_URL: ${DATABASE_URL}
gatekeeper-redis:
image: redis:7.0.5-alpine
command: redis-server --requirepass ${GK_REDIS_PASSWORD} --appendonly yes
ports:
- "6379:6379"
volumes:
- ${MNT_GATEKEEPER}:/data
website:
image: doceazedo/ssn-website:latest
pull_policy: always
labels:
- "traefik.enable=true"
- "traefik.http.routers.website.entrypoints=web"
- "traefik.http.routers.website.rule=Host(`${PUBLIC_BASE_DOMAIN}`)"
ports:
- "3002:3000"
environment:
PUBLIC_WEBSITE_URL: ${PUBLIC_WEBSITE_URL}
PUBLIC_IDENTITY_URL: ${PUBLIC_IDENTITY_URL}
LOCAL_IDENTITY_URL: ${LOCAL_IDENTITY_URL}
DATABASE_URL: ${DATABASE_URL}
MERCADOPAGO_ACCESS_TOKEN: ${MERCADOPAGO_ACCESS_TOKEN}
MERCADOPAGO_WEBHOOK_SIGNATURE: ${MERCADOPAGO_WEBHOOK_SIGNATURE}
LOCAL_COMMANDER_URL: ${LOCAL_COMMANDER_URL}
COMMANDER_TOKEN: ${COMMANDER_TOKEN}
DISCORD_WEBHOOK_DONATIONS: ${DISCORD_WEBHOOK_DONATIONS}
DISCORD_WEBHOOK_PAYMENTS: ${DISCORD_WEBHOOK_PAYMENTS}
melonbot:
image: doceazedo/ssn-melonbot:latest
pull_policy: always
environment:
PUBLIC_DISCORD_CLIENT_ID: ${PUBLIC_DISCORD_CLIENT_ID}
DISCORD_CLIENT_SECRET: ${DISCORD_CLIENT_SECRET}
DISCORD_TOKEN: ${DISCORD_TOKEN}
LOCAL_COMMANDER_URL: ${LOCAL_COMMANDER_URL}
restart: always
minecraft-proxy:
image: amazoncorretto:21
command: java -Xms512M -Xmx1024M -jar BungeeCord.jar
stdin_open: true
tty: true
ports:
- "25565:25565"
working_dir: /data
volumes:
- ./servers/0-proxy:/data
restart: on-failure
environment:
LUCKPERMS_SERVER: "global"
LUCKPERMS_STORAGE_METHOD: "postgresql"
LUCKPERMS_DATA_ADDRESS: "warehouse"
LUCKPERMS_DATA_DATABASE: ${POSTGRES_DB}
LUCKPERMS_DATA_USERNAME: ${POSTGRES_USER}
LUCKPERMS_DATA_PASSWORD: ${POSTGRES_PASSWORD}
minecraft-queue:
image: amazoncorretto:21
command: java --add-opens java.base/java.net=ALL-UNNAMED -Xms512M -Xmx1024M -XX:+UseG1GC -XX:+ParallelRefProcEnabled -XX:MaxGCPauseMillis=200 -XX:+UnlockExperimentalVMOptions -XX:+DisableExplicitGC -XX:+AlwaysPreTouch -XX:G1NewSizePercent=30 -XX:G1MaxNewSizePercent=40 -XX:G1HeapRegionSize=8M -XX:G1ReservePercent=20 -XX:G1HeapWastePercent=5 -XX:G1MixedGCCountTarget=4 -XX:InitiatingHeapOccupancyPercent=15 -XX:G1MixedGCLiveThresholdPercent=90 -XX:G1RSetUpdatingPauseTimePercent=5 -XX:SurvivorRatio=32 -XX:+PerfDisableSharedMem -XX:MaxTenuringThreshold=1 -Dusing.aikars.flags=https://mcflags.emc.gs -Daikars.new.flags=true -jar paper-1.21.1-116.jar
stdin_open: true
tty: true
ports:
- "25561:25561"
- "25572:25572"
working_dir: /data
volumes:
- ./servers/1-queue:/data
environment:
PUBLIC_BASE_DOMAIN: ${PUBLIC_BASE_DOMAIN}
PUBLIC_GATEKEEPER_URL: ${PUBLIC_GATEKEEPER_URL}
LOCAL_IDENTITY_URL: ${LOCAL_IDENTITY_URL}
CATRACA_IDENTITY_TOKEN: ${CATRACA_IDENTITY_TOKEN}
GK_REDIS_HOST: ${GK_REDIS_HOST}
GK_REDIS_PORT: ${GK_REDIS_PORT}
GK_REDIS_PASSWORD: ${GK_REDIS_PASSWORD}
LUCKPERMS_SERVER: "global"
LUCKPERMS_STORAGE_METHOD: "postgresql"
LUCKPERMS_DATA_ADDRESS: "warehouse"
LUCKPERMS_DATA_DATABASE: ${POSTGRES_DB}
LUCKPERMS_DATA_USERNAME: ${POSTGRES_USER}
LUCKPERMS_DATA_PASSWORD: ${POSTGRES_PASSWORD}
restart: on-failure
minecraft-main:
image: amazoncorretto:21
command: java --add-opens java.base/java.net=ALL-UNNAMED -Xms${RAM_MIN} -Xmx${RAM_MAX} -XX:+UseG1GC -XX:+ParallelRefProcEnabled -XX:MaxGCPauseMillis=200 -XX:+UnlockExperimentalVMOptions -XX:+DisableExplicitGC -XX:+AlwaysPreTouch -XX:G1NewSizePercent=30 -XX:G1MaxNewSizePercent=40 -XX:G1HeapRegionSize=8M -XX:G1ReservePercent=20 -XX:G1HeapWastePercent=5 -XX:G1MixedGCCountTarget=4 -XX:InitiatingHeapOccupancyPercent=15 -XX:G1MixedGCLiveThresholdPercent=90 -XX:G1RSetUpdatingPauseTimePercent=5 -XX:SurvivorRatio=32 -XX:+PerfDisableSharedMem -XX:MaxTenuringThreshold=1 -Dusing.aikars.flags=https://mcflags.emc.gs -Daikars.new.flags=true -jar paper-1.21.1-116.jar
stdin_open: true
tty: true
labels:
- "traefik.enable=true"
- "traefik.http.routers.minecraft-main.entrypoints=web"
- "traefik.http.routers.minecraft-main.rule=Host(`cmd.${PUBLIC_BASE_DOMAIN}`)"
- "traefik.http.services.minecraft-main.loadbalancer.server.port=25574"
ports:
- "25562:25562" # minecraft
- "25573:25573" # rcon
- "25574:25574" # commander
working_dir: /data
volumes:
- ./servers/2-main:/data
environment:
LOCAL_IDENTITY_URL: ${LOCAL_IDENTITY_URL}
CATRACA_IDENTITY_TOKEN: ${CATRACA_IDENTITY_TOKEN}
COMMANDER_TOKEN: ${COMMANDER_TOKEN}
GK_REDIS_HOST: ${GK_REDIS_HOST}
GK_REDIS_PORT: ${GK_REDIS_PORT}
GK_REDIS_PASSWORD: ${GK_REDIS_PASSWORD}
LUCKPERMS_SERVER: "global"
LUCKPERMS_STORAGE_METHOD: "postgresql"
LUCKPERMS_DATA_ADDRESS: "warehouse"
LUCKPERMS_DATA_DATABASE: ${POSTGRES_DB}
LUCKPERMS_DATA_USERNAME: ${POSTGRES_USER}
LUCKPERMS_DATA_PASSWORD: ${POSTGRES_PASSWORD}
restart: on-failure
volumes:
warehouse:
gatekeeper: