Files
move-data-nas/packaging/debian/lib/systemd/system/syncserver.service
T
darroyo 4cc93c7747 fix: self-healing permissions on /var/lib/syncserver
- systemd: add ExecStartPre to chown -R the data dir before every start
- postinst: add chown -R after creating dirs to fix ownership on upgrades

This prevents the service from failing if dirs were created by root or
drifted ownership after a manual run.
2026-07-07 15:41:10 -04:00

29 lines
699 B
Desktop File

[Unit]
Description=SyncServer - File sync orchestrator with Wake-on-LAN and web UI
Documentation=https://github.com/syncserver/syncserver
After=network-online.target
Wants=network-online.target
[Service]
Type=simple
User=syncserver
Group=syncserver
ExecStartPre=/bin/chown -R syncserver:syncserver /var/lib/syncserver
ExecStart=/usr/bin/syncserver --config /etc/syncserver/config.yaml --data-dir /var/lib/syncserver
Restart=on-failure
RestartSec=5
StandardOutput=journal
StandardError=journal
SyslogIdentifier=syncserver
# Hardening
NoNewPrivileges=true
PrivateTmp=true
ProtectSystem=strict
ProtectHome=true
ReadWritePaths=/var/lib/syncserver /run
UMask=0077
[Install]
WantedBy=multi-user.target