mirror of
https://github.com/Stunkymonkey/nixos.git
synced 2025-05-24 09:54:40 +02:00
system/avahi: modularize
This commit is contained in:
parent
06b1294532
commit
87c3677396
5 changed files with 24 additions and 15 deletions
23
modules/system/avahi/default.nix
Normal file
23
modules/system/avahi/default.nix
Normal file
|
@ -0,0 +1,23 @@
|
|||
# avahi related settings
|
||||
{ config, inputs, lib, options, pkgs, ... }:
|
||||
let
|
||||
cfg = config.my.system.avahi;
|
||||
in
|
||||
{
|
||||
options.my.system.avahi = with lib; {
|
||||
enable = mkEnableOption "avahi configuration";
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
services.avahi = {
|
||||
enable = true;
|
||||
nssmdns = true;
|
||||
publish = {
|
||||
enable = true;
|
||||
addresses = true;
|
||||
workstation = true;
|
||||
userServices = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,6 +1,7 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
./avahi
|
||||
./docker
|
||||
./podman
|
||||
];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue