You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
518 B
Nix
23 lines
518 B
Nix
2 months ago
|
{ config, lib, ... }:
|
||
|
let
|
||
|
cfgAvahi = config.services.avahi;
|
||
|
avahiMDNS = cfgAvahi.enable && (cfgAvahi.nssmdns4 || cfgAvahi.nssmdns6);
|
||
|
cfgResolved = config.services.resolved;
|
||
|
# TODO check settings when cfgResolved.settings exist
|
||
|
resolvedMDNS = cfgResolved.enable;
|
||
|
in
|
||
|
{
|
||
|
config = {
|
||
|
|
||
|
assertions = [
|
||
|
{
|
||
|
assertion = !(avahiMDNS && cfgResolved.enable);
|
||
|
message = ''
|
||
|
systemd-resolved is enabled while Avahi mDNS is enabled, disable one of both!
|
||
|
'';
|
||
|
}
|
||
|
];
|
||
|
|
||
|
};
|
||
|
}
|