nixos/sogo: replace systemd preStart with ExecStartPre for tmp watcher

This commit is contained in:
h7x4
2026-07-31 03:18:43 +09:00
parent 77b0c5aa55
commit 1168ec307c
+5 -6
View File
@@ -151,16 +151,15 @@ in
description = "SOGo tmpwatch";
startAt = [ "hourly" ];
script = ''
SOGOSPOOL=/var/lib/sogo/spool
find "$SOGOSPOOL" -type f -user sogo -atime +23 -delete > /dev/null
find "$SOGOSPOOL" -mindepth 1 -type d -user sogo -empty -delete > /dev/null
'';
serviceConfig = {
Type = "oneshot";
ExecStart = [
"find /var/lib/sogo/spool -type f -user sogo -atime +23 -delete"
"find /var/lib/sogo/spool -mindepth 1 -type d -user sogo -empty -delete"
];
ProtectSystem = "strict";
ProtectHome = true;
PrivateTmp = true;