Commit 789d214
fix(compose): route container logs to journald to bound disk usage (#2853)
* fix(compose): route container logs to journald to bound disk usage
Adds `logging: driver: journald` to all four services in
docker-compose.yml.tmpl with per-service tags so the host's
systemd-journald handles rotation/retention. Previously the default
json-file driver wrote unbounded `*-json.log` files under
/var/lib/docker/containers/, which on long-running Pi installs could
fill the SD card (issue #2304 reported a 19 GB anthias-viewer log).
Updates the docs to explain the new behavior and document `journalctl`
access via the per-service `CONTAINER_TAG=` filter.
Refs #2304
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* fix: cover anthias-caddy with journald driver, scope docs accurately
Address Copilot review on #2853:
- enable_ssl.sh's generated SSL override added anthias-caddy without a
logging block, so the caddy sidecar would still write unbounded
json-file logs. Add the journald driver + tag there too.
- Docs implied no Anthias container writes json-file logs, which was
not true once SSL was enabled. Scope the statement to the four core
services plus the optional caddy sidecar.
- Lead the journalctl examples with sudo (always works) and add a note
explaining when the installer-granted adm group lets you drop sudo.
Refs #2304
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* docs: document one-time cleanup of pre-existing json-file logs
Address Copilot review on #2853: the journald switch only affects
future writes, so devices upgrading from the old json-file driver
still have the historical *-json.log files on disk and need to
reclaim that space manually. Add a note + a safe truncate command
(deleting while docker has the file open is unsafe; truncate -s 0
zeroes them in place).
Refs #2304
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 8cc7411 commit 789d214
3 files changed
Lines changed: 74 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
201 | 201 | | |
202 | 202 | | |
203 | 203 | | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
204 | 208 | | |
205 | 209 | | |
206 | 210 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
32 | 36 | | |
33 | 37 | | |
34 | 38 | | |
| |||
55 | 59 | | |
56 | 60 | | |
57 | 61 | | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
58 | 66 | | |
59 | 67 | | |
60 | 68 | | |
| |||
94 | 102 | | |
95 | 103 | | |
96 | 104 | | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
97 | 109 | | |
98 | 110 | | |
99 | 111 | | |
| |||
105 | 117 | | |
106 | 118 | | |
107 | 119 | | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
108 | 124 | | |
109 | 125 | | |
110 | 126 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
15 | | - | |
16 | | - | |
17 | | - | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
18 | 36 | | |
19 | 37 | | |
20 | 38 | | |
| |||
59 | 77 | | |
60 | 78 | | |
61 | 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 | + | |
62 | 113 | | |
63 | 114 | | |
64 | 115 | | |
| |||
0 commit comments