Commit 4f4fb34
authored
fix(selfhost): add memory limits to docker-compose services (#2569)
* fix(selfhost): add memory limits to docker-compose services
No service declared a memory or CPU limit, including the core gittensory
app itself. Any --profile combination let one runaway optional service
(Ollama loading a multi-GB model, Postgres, Qdrant, or the whole
observability stack) exhaust host RAM and OOM-kill or starve the core
review pipeline container instead of the intended optional service --
the exact gap #1828 calls out, with zero mitigation anywhere in the
compose file.
Add deploy.resources.limits.memory to the core gittensory/redis
services and every heavyweight optional service (postgres, qdrant,
ollama, prometheus, loki, tempo, grafana), each overridable via a
documented .env variable so an operator can size a bigger/smaller host
without editing the compose file.
* fix(selfhost): guard the possibly-undefined service lookup in the resource-limits test1 parent 32be1ba commit 4f4fb34
3 files changed
Lines changed: 112 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
192 | 192 | | |
193 | 193 | | |
194 | 194 | | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
195 | 209 | | |
196 | 210 | | |
197 | 211 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
98 | 98 | | |
99 | 99 | | |
100 | 100 | | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
101 | 107 | | |
102 | 108 | | |
103 | 109 | | |
| |||
131 | 137 | | |
132 | 138 | | |
133 | 139 | | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
134 | 144 | | |
135 | 145 | | |
136 | 146 | | |
| |||
147 | 157 | | |
148 | 158 | | |
149 | 159 | | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
150 | 164 | | |
151 | 165 | | |
152 | 166 | | |
| |||
218 | 232 | | |
219 | 233 | | |
220 | 234 | | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
221 | 239 | | |
222 | 240 | | |
223 | 241 | | |
| |||
251 | 269 | | |
252 | 270 | | |
253 | 271 | | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
254 | 278 | | |
255 | 279 | | |
256 | 280 | | |
| |||
308 | 332 | | |
309 | 333 | | |
310 | 334 | | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
311 | 339 | | |
312 | 340 | | |
313 | 341 | | |
| |||
352 | 380 | | |
353 | 381 | | |
354 | 382 | | |
| 383 | + | |
| 384 | + | |
| 385 | + | |
| 386 | + | |
355 | 387 | | |
356 | 388 | | |
357 | 389 | | |
| |||
419 | 451 | | |
420 | 452 | | |
421 | 453 | | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
| 457 | + | |
422 | 458 | | |
423 | 459 | | |
424 | 460 | | |
| |||
494 | 530 | | |
495 | 531 | | |
496 | 532 | | |
| 533 | + | |
| 534 | + | |
| 535 | + | |
| 536 | + | |
497 | 537 | | |
498 | 538 | | |
499 | 539 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 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 | + | |
0 commit comments