From 7f061323bf65256089c8316fbdb4b51bdf3b9a0d Mon Sep 17 00:00:00 2001 From: niten Date: Sun, 19 Mar 2023 10:18:46 -0700 Subject: [PATCH] Corrected some arguments to suanni-server. --- module.nix | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/module.nix b/module.nix index d5cc5a3..b828f2d 100644 --- a/module.nix +++ b/module.nix @@ -65,7 +65,7 @@ in { }; }; - mqtt-server = { + mqtt-client = { host = mkOption { type = str; description = "Hostname of the MQTT server."; @@ -108,22 +108,24 @@ in { serviceConfig = { DynamicUser = true; LoadCredential = [ - "syno.passwd:${cfg.synology.password-file}" - "mqtt.passwd:${cfg.mqtt-server.password-file}" + "syno.passwd:${cfg.synology-client.password-file}" + "mqtt.passwd:${cfg.mqtt-client.password-file}" ]; ExecStart = pkgs.writeShellScript "suanni-server.sh" (concatStringsSep " " ([ "suanni-server" "--hostname=${cfg.event-listener.hostname}" "--port=${toString cfg.event-listener.port}" - "--synology-host=${cfg.synology.host}" - "--synology-port=${toString cfg.synology.port}" - "--synology-user=${cfg.synology.username}" + "--synology-host=${cfg.synology-client.host}" + "--synology-port=${toString cfg.synology-client.port}" + "--synology-user=${cfg.synology-client.username}" "--synology-password-file=$CREDENTIALS_DIRECTORY/syno.passwd" - "--mqtt-host=${cfg.mqtt.host}" - "--mqtt-port=${toString cfg.mqtt.port}" - "--mqtt-user=${cfg.mqtt.username}" + "--mqtt-host=${cfg.mqtt-client.host}" + "--mqtt-port=${toString cfg.mqtt-client.port}" + "--mqtt-user=${cfg.mqtt-client.username}" "--mqtt-password-file=$CREDENTIALS_DIRECTORY/mqtt.passwd" + "--objectifier-host=${cfg.objectifier-client.host}" + "--objectifier-port=${cfg.objectifier-client.port}" ]) ++ (optional cfg.verbose "--verbose")); }; };