mirror of
https://github.com/CyberMind-FR/secubox-deb.git
synced 2026-07-29 09:14:33 +00:00
Hub + portal stayed `inactive (dead)` on real-hardware boot. The journal error was `Failed to set up mount namespacing: /run/systemd/ unit-root/run/secubox: No such file or directory` at the NAMESPACE step. Root cause: 96 services declare `RuntimeDirectory=secubox` without the matching `RuntimeDirectoryPreserve=yes`. When any of them stops (including any of the LXC-backed services that fail their health probe and Restart=on-failure for a few cycles), systemd removes /run/secubox on the way out. The next service with the same RuntimeDirectory= that tries to namespace its inputs hits the gap and falls into 226/NAMESPACE failure — Restart hammers a few times, then the unit goes failed-permanent. Earlier fmrelay + sentinelle units got the fix individually (v2.12.0/v2.12.3 era). Now applied to all 96 remaining units in a single sweep via: sed -i '/^RuntimeDirectory=secubox/a RuntimeDirectoryPreserve=yes' "$f" No version bumps in changelog — `dpkg -i --force-depends` in the live-USB slipstream picks up the new .deb regardless of version number.
25 lines
568 B
Desktop File
25 lines
568 B
Desktop File
[Unit]
|
|
Description=SecuBox Ad Guard API
|
|
After=network.target secubox-core.service
|
|
Requires=secubox-core.service
|
|
|
|
[Service]
|
|
Type=simple
|
|
User=secubox
|
|
Group=secubox
|
|
WorkingDirectory=/usr/lib/secubox/ad-guard
|
|
ExecStart=/usr/bin/python3 -m uvicorn api.main:app --uds /run/secubox/ad-guard.sock --log-level warning
|
|
Restart=on-failure
|
|
RestartSec=5
|
|
UMask=0000
|
|
|
|
NoNewPrivileges=true
|
|
RuntimeDirectory=secubox
|
|
RuntimeDirectoryPreserve=yes
|
|
RuntimeDirectoryMode=0775
|
|
|
|
ReadWritePaths=/run/secubox /var/lib/secubox /etc/secubox /var/log/secubox
|
|
|
|
[Install]
|
|
WantedBy=multi-user.target
|