Watch
0
0
Fork
You've already forked hyperhive
0

start tuwunel after the container is up, under its own 30 min limit

This commit is contained in:
atlas 2026-11-28 02:48:25 +01:00 • committed by mara
commit ba0f9c6264

View file

@ -969,6 +969,11 @@ in
services.hyperhive.swarmContainer = {
inherit privateNetwork;
writesOwnResolvConf = false;
# The container's start limit is one minute and tuwunel's start
# replays the write-ahead log, which RocksDB redoes from the start
# at every open: a start killed before it ends makes no progress.
# tuwunel starts after the container is up, under its own limit.
startAfterReady = [ "tuwunel" ];
};
# Swarm-internal trust reaches tuwunel at RUNTIME, not via
@ -1102,6 +1107,13 @@ in
# Upstream's `ProtectSystem = "strict"` leaves `/run` read-only.
systemd.services.tuwunel.serviceConfig.ReadWritePaths = [ socketDir ];
# tuwunel asks systemd for 30 s more every 15 s while it opens the
# database (`EXTEND_TIMEOUT_USEC`), which moves the deadline past
# this value for as long as it reports; this is the limit when it does
# not. 30 min is ten times the 3 min of CPU a replay has already used
# without ending.
systemd.services.tuwunel.serviceConfig.TimeoutStartSec = "30min";
# The probe's file lives in upstream's `RuntimeDirectory`.
systemd.services.tuwunel.serviceConfig.ExecStartPre =
(fallocateProbe.serviceConfig "/var/lib/${stateName}").ExecStartPre;