diff options
author | Bernardo Meurer <bernardo@meurer.org> | 2024-01-29 11:31:12 -0500 |
---|---|---|
committer | Bernardo Meurer <bernardo@meurer.org> | 2024-01-29 11:31:12 -0500 |
commit | 392b32b2af4ea9c02e1c360cdf6d8e337ed59f56 (patch) | |
tree | f40daa72ec693226fd4fbb66fa9932d7e2269c11 | |
parent | 58c2a31a59bc10db8ce70727f418b45b6b41785a (diff) |
nixos/moonraker: fix update_manager.enable_system_updates being [bool] and not bool
-rw-r--r-- | nixos/modules/services/misc/moonraker.nix | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/nixos/modules/services/misc/moonraker.nix b/nixos/modules/services/misc/moonraker.nix index 4e419aafa990b..f043cc83bf052 100644 --- a/nixos/modules/services/misc/moonraker.nix +++ b/nixos/modules/services/misc/moonraker.nix @@ -103,17 +103,18 @@ in { config = mkIf cfg.enable { warnings = [] - ++ optional (cfg.settings.update_manager.enable_system_updates or false) - ''Enabling update_manager is not supported on NixOS and will lead to non-removable warnings in some clients.'' - ++ optional (cfg.configDir != null) - '' - services.moonraker.configDir has been deprecated upstream and will be removed. - - Action: ${ - if cfg.configDir == unifiedConfigDir then "Simply remove services.moonraker.configDir from your config." - else "Move files from `${cfg.configDir}` to `${unifiedConfigDir}` then remove services.moonraker.configDir from your config." - } - ''; + ++ (optional (head (cfg.settings.update_manager.enable_system_updates or [false])) '' + Enabling system updates is not supported on NixOS and will lead to non-removable warnings in some clients. + '') + ++ (optional (cfg.configDir != null) '' + services.moonraker.configDir has been deprecated upstream and will be removed. + + Action: ${ + if cfg.configDir == unifiedConfigDir + then "Simply remove services.moonraker.configDir from your config." + else "Move files from `${cfg.configDir}` to `${unifiedConfigDir}` then remove services.moonraker.configDir from your config." + } + ''); assertions = [ { |