home | systemd - fix? mbsync*

This commit is contained in:
Don Harper 2023-12-26 23:15:48 -06:00
parent f614c30ae5
commit b8d47c96f7

View file

@ -1,40 +1,46 @@
{...}:
{
systemd.user = {
timers.mbsync = {
Timer = {
OnUnitActiveSec = "5m";
AccuracySec = "1m";
};
Install = {
WantedBy = ["timers.target"];
};
};
services.mbsync = {
serviceConfig = {
Type = "oneshot";
Environment = "PATH=/run/current-system/sw/bin";
Service = {
ExecStart = "/home/don/bin/mbsync";
RuntimeMaxSec = "3m";
Environment = "PATH=/run/current-system/sw/bin";
Type = "oneshot";
};
Install = {
WantedBy = [ "mbsync.timer" ];
};
};
services."mbsync-all" = {
serviceConfig = {
Type = "oneshot";
Environment = "PATH=/run/current-system/sw/bin";
Service = {
ExecStart = "/home/don/bin/mbsync gmail";
RuntimeMaxSec = "3m";
Environment = "PATH=/run/current-system/sw/bin";
Type = "oneshot";
};
};
timers.mbsync = {
timerConfig = {
OnBoot = "1m";
OnUnitActiveSec = "5m";
AccuracySec = "1m";
Unit = "mbsync.service";
Install = {
WantedBy = ["mbsync-all.timer"];
};
};
};
timers."mbsync-all" = {
timerConfig = {
OnBoot = "10m";
OnUnitActiveSec = "14m";
Timer = {
AccuracySec = "1m";
Unit = "mbsync-all.service";
OnUnitActiveSec = "14m";
};
};
Install = {
WantedBy = ["timers.target"];
};
};
};
}