Common/avahi: remove 23.11 compatibity on config

This commit is contained in:
Toast 2024-06-03 01:02:39 +02:00
parent 6ac0973357
commit 7de1a1bad7

View file

@ -1,23 +1,6 @@
{config, ...}: let
old = {
nssmdns = true;
};
new = {
{config, ...}: {
services.avahi = {
enable = true;
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
);
}