fix(process): drop OOMPolicy from systemd-run --scope argv

OOMPolicy is a service-unit property; systemd-run --user --scope
rejects it with 'Unknown assignment: OOMPolicy=kill'. The availability
probe therefore always failed in supervised Linux gateways, making
restart-safe cron worker dispatch (systemd scope) permanently
unavailable and falling back to in-cgroup workers.

MemoryMax + MemoryAccounting remain; OOMPolicy adds nothing for a
transient scope (no service manager to act on the OOM event).
This commit is contained in:
gkd2323c
2026-09-04 01:22:21 +08:00
committed by kshitij
parent bc1330eebc
commit 611ee856c5
-1
View File
@@ -131,7 +131,6 @@ def _systemd_scope_argv(binary: str, unit_name: str, *argv: str) -> List[str]:
binary, "--user", "--scope", "--quiet", "--unit", unit_name, "--collect",
"--property", "MemoryAccounting=yes",
"--property", f"MemoryMax={_worker_memory_max_bytes()}",
"--property", "OOMPolicy=kill",
"--", *argv,
]