aboutsummaryrefslogtreecommitdiff
path: root/modules/services/lieer-accounts.nix
diff options
context:
space:
mode:
authorTad Fisher <tadfisher@gmail.com>2020-02-20 23:30:59 -0800
committerRobert Helgesson <robert@rycee.net>2020-03-07 15:13:50 +0100
commit9f46d516fa13df70768a3211827d14f456fa6e85 (patch)
tree27cc1c12e61b3cc29f64847d171ffd2ef69b0dac /modules/services/lieer-accounts.nix
parent60a939bd01dc66d1cbdc85a3f6dc78e4ca092537 (diff)
services.lieer: add module
Add 'services.lieer', which generates systemd timer and service units to synchronize a Gmail account with lieer. Per-account configuration lives in 'accounts.email.accounts.<name>.lieer.sync'.
Diffstat (limited to 'modules/services/lieer-accounts.nix')
-rw-r--r--modules/services/lieer-accounts.nix25
1 files changed, 25 insertions, 0 deletions
diff --git a/modules/services/lieer-accounts.nix b/modules/services/lieer-accounts.nix
new file mode 100644
index 00000000000..187f7dff980
--- /dev/null
+++ b/modules/services/lieer-accounts.nix
@@ -0,0 +1,25 @@
+{ lib, ... }:
+
+with lib;
+
+{
+ options.lieer.sync = {
+ enable = mkEnableOption "lieer synchronization service";
+
+ frequency = mkOption {
+ type = types.str;
+ default = "*:0/5";
+ description = ''
+ How often to synchronize the account.
+ </para><para>
+ This value is passed to the systemd timer configuration as the
+ onCalendar option. See
+ <citerefentry>
+ <refentrytitle>systemd.time</refentrytitle>
+ <manvolnum>7</manvolnum>
+ </citerefentry>
+ for more information about the format.
+ '';
+ };
+ };
+}