From a9413c7794392ed19985caab05c58079a3311fcd Mon Sep 17 00:00:00 2001 From: Felix Buehler Date: Sun, 27 Oct 2024 18:58:02 +0100 Subject: [PATCH] nixos/octoprint: fix ipv6 host --- nixos/modules/services/misc/octoprint.nix | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/nixos/modules/services/misc/octoprint.nix b/nixos/modules/services/misc/octoprint.nix index 42b2926a7a1e6..d8e4c9c302b38 100644 --- a/nixos/modules/services/misc/octoprint.nix +++ b/nixos/modules/services/misc/octoprint.nix @@ -5,10 +5,9 @@ let baseConfig = { plugins.curalegacy.cura_engine = "${pkgs.curaengine_stable}/bin/CuraEngine"; - server.host = cfg.host; server.port = cfg.port; webcam.ffmpeg = "${pkgs.ffmpeg.bin}/bin/ffmpeg"; - }; + } // lib.optionalAttrs (cfg.host != null) {server.host = cfg.host;}; fullConfig = lib.recursiveUpdate cfg.extraConfig baseConfig; @@ -29,8 +28,8 @@ in enable = lib.mkEnableOption "OctoPrint, web interface for 3D printers"; host = lib.mkOption { - type = lib.types.str; - default = "0.0.0.0"; + type = lib.types.nullOr lib.types.str; + default = null; description = '' Host to bind OctoPrint to. '';