From cf34e7c222b64f7913eaf8b6015e72684d722df2 Mon Sep 17 00:00:00 2001 From: Toast Date: Thu, 14 Dec 2023 10:04:12 +0100 Subject: [PATCH] Services/avahi: rename moved option --- roles/common/services/avahi.nix | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/roles/common/services/avahi.nix b/roles/common/services/avahi.nix index 2891e8d..ef9d747 100755 --- a/roles/common/services/avahi.nix +++ b/roles/common/services/avahi.nix @@ -1,8 +1,19 @@ { config, ... }: - -{ - services.avahi = { - enable = true; +let + old = { nssmdns = true; }; + new = { + nssmdns4 = true; + }; +in +{ + /* + NixOS 24.05 changed the option for mnds to be able to turn on/off IPv6 + 23.11 doesn't support this, so I need to use the conditional to be able to + use the same config for both + */ + services.avahi = { + enable = true; + } // (if config.system.nixos.release == "23.11" then old else new); }