add service to flush the msmtp queue
This commit is contained in:
parent
9d1c35311c
commit
8b13219861
1 changed files with 23 additions and 1 deletions
|
@ -8,7 +8,6 @@ in
|
|||
msmtp
|
||||
neomutt
|
||||
notmuch
|
||||
pass
|
||||
w3m
|
||||
links2
|
||||
];
|
||||
|
@ -81,6 +80,7 @@ in
|
|||
|
||||
systemd.user = {
|
||||
|
||||
# Service and timer to sync imap to local maildir
|
||||
services.mbsync = {
|
||||
enable = true;
|
||||
after = [ "graphical.target" "network-online.target" ];
|
||||
|
@ -102,5 +102,27 @@ in
|
|||
};
|
||||
};
|
||||
|
||||
# service and timer to flush the msmtp queue
|
||||
services.flush-msmtpq = {
|
||||
enable = true;
|
||||
after = [ "graphical.target" "network-online.target" ];
|
||||
script = ''
|
||||
${pkgs.msmtp}/bin/msmtp-queue -r
|
||||
'';
|
||||
serviceConfig = {
|
||||
Type = "oneshot";
|
||||
};
|
||||
};
|
||||
|
||||
timers.flush-msmtpq = {
|
||||
enable = true;
|
||||
wantedBy = [ "timers.target" ];
|
||||
timerConfig = {
|
||||
Unit = "flush-msmtpq.service";
|
||||
OnBootSec = "11m";
|
||||
OnUnitInactiveSec = "13m";
|
||||
};
|
||||
};
|
||||
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue