assets/systemd/roowho2.service: fix permissions for walld

This commit is contained in:
2026-07-30 19:14:41 +09:00
parent 89bf5a831a
commit 2271aedfd3
+16 -5
View File
@@ -1,23 +1,35 @@
[Unit] [Unit]
Wants=network-online.target Wants=network-online.target dbus.socket
After=network-online.target After=network-online.target dbus.socket
[Service] [Service]
Type=notify Type=notify
Restart=on-failure Restart=on-failure
DynamicUser=true DynamicUser=true
# Needed for walld to open tty devices
SupplementaryGroups=tty
ExecStart=/usr/bin/roowhod ExecStart=/usr/bin/roowhod
ConfigurationDirectory=roowho2 ConfigurationDirectory=roowho2
Environment=DBUS_SYSTEM_BUS_ADDRESS=unix:path=/run/dbus/system_bus_socket
AmbientCapabilities=CAP_DAC_READ_SEARCH AmbientCapabilities=CAP_DAC_READ_SEARCH
CapabilityBoundingSet=CAP_DAC_READ_SEARCH CapabilityBoundingSet=CAP_DAC_READ_SEARCH
DeviceAllow=
# walld needs access to tty/pts devices.
DeviceAllow=char-tty rw
DeviceAllow=char-pts rw
PrivateDevices=false
# Might use /proc/<pid>/stat to determine the caller's PID + UID
ProtectProc=default
DevicePolicy=closed DevicePolicy=closed
LockPersonality=true LockPersonality=true
MemoryDenyWriteExecute=true MemoryDenyWriteExecute=true
NoNewPrivileges=true NoNewPrivileges=true
PrivateDevices=true
PrivateIPC=true PrivateIPC=true
PrivateMounts=true PrivateMounts=true
PrivateTmp=true PrivateTmp=true
@@ -28,7 +40,6 @@ ProtectHostname=true
ProtectKernelLogs=true ProtectKernelLogs=true
ProtectKernelModules=true ProtectKernelModules=true
ProtectKernelTunables=true ProtectKernelTunables=true
ProtectProc=invisible
RemoveIPC=true RemoveIPC=true
RestrictAddressFamilies=AF_INET RestrictAddressFamilies=AF_INET
RestrictAddressFamilies=AF_INET6 RestrictAddressFamilies=AF_INET6