parent
96d6344b13
commit
d6e9df1e1a
@ -0,0 +1,37 @@ |
||||
{ config, lib, pkgs, ... }: |
||||
|
||||
with lib; |
||||
|
||||
let |
||||
|
||||
cfg = config.services.canto-daemon; |
||||
|
||||
in { |
||||
|
||||
##### interface |
||||
|
||||
options = { |
||||
|
||||
services.canto-daemon { |
||||
enable = mkOption { |
||||
type = types.bool; |
||||
default = false; |
||||
description = "Whether to enable the canto RSS daemon."; |
||||
}; |
||||
}; |
||||
|
||||
}; |
||||
|
||||
##### implementation |
||||
|
||||
config = mkIf cfg.enable { |
||||
|
||||
systemd.user.services.canto-next = { |
||||
description = "Canto RSS Daemon"; |
||||
after = [ "network.target" ]; |
||||
wantedBy = [ "default.target" ]; |
||||
serviceConfig.ExecStart = "${pkgs.canto-daemon}/bin/canto-daemon"; |
||||
TimeoutStopSec = 10; |
||||
}; |
||||
}; |
||||
} |
Loading…
Reference in new issue