chute: user -> target

This commit is contained in:
Peter Selby 2021-12-22 12:05:21 -08:00
parent 23ab0463ce
commit 330f425d13

View File

@ -46,7 +46,7 @@ let
default = null; default = null;
}; };
jabber-user = mkOption { jabber-target = mkOption {
type = nullOr str; type = nullOr str;
description = "User to which logs will be sent."; description = "User to which logs will be sent.";
example = "target@my.server.org"; example = "target@my.server.org";
@ -66,8 +66,8 @@ let
path = [ package ]; path = [ package ];
environmentFile = environment-file; environmentFile = environment-file;
execStart = let execStart = let
jabber-string = optionalString (cfg.jabber-jid != null && cfg.jabber-user != null) jabber-string = optionalString (cfg.jabber-jid != null && cfg.jabber-target != null)
"--jabber-jid=${cfg.jabber-jid} --target-jid=${cfg.jabber-user}"; "--jabber-jid=${cfg.jabber-jid} --target-jid=${cfg.jabber-target}";
in "${package}/bin/chute --currency=${currency} --stop-at-percent=${toString stop-at-percent} ${jabber-string}"; in "${package}/bin/chute --currency=${currency} --stop-at-percent=${toString stop-at-percent} ${jabber-string}";
privateNetwork = false; privateNetwork = false;
addressFamilies = [ "AF_INET" ]; addressFamilies = [ "AF_INET" ];