nixos/octoprint: fix setting host causing port to be unset

This was because of the non-recursive update of the attrset.
This commit is contained in:
Jade Lovelace 2025-05-28 18:19:16 -07:00
parent a6a1e640c5
commit ab320c9bcd

View file

@ -8,11 +8,11 @@ let
cfg = config.services.octoprint;
baseConfig = {
baseConfig = lib.recursiveUpdate {
plugins.curalegacy.cura_engine = "${pkgs.curaengine_stable}/bin/CuraEngine";
server.port = cfg.port;
webcam.ffmpeg = "${pkgs.ffmpeg.bin}/bin/ffmpeg";
} // lib.optionalAttrs (cfg.host != null) { server.host = cfg.host; };
} (lib.optionalAttrs (cfg.host != null) { server.host = cfg.host; });
fullConfig = lib.recursiveUpdate cfg.extraConfig baseConfig;