From 05571aa5ed5eb898be468bff237657914f7e9dcf Mon Sep 17 00:00:00 2001 From: Alan Pearce Date: Sun, 29 Apr 2018 15:00:53 +0200 Subject: Delay startup of non-essential services --- modules/services/zeroconf.nix | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'modules/services') diff --git a/modules/services/zeroconf.nix b/modules/services/zeroconf.nix index aa4b47e8..0b428c54 100644 --- a/modules/services/zeroconf.nix +++ b/modules/services/zeroconf.nix @@ -1,7 +1,16 @@ -{ config, pkgs, ... }: +{ config, pkgs, lib, ... }: { services.avahi = { enable = true; nssmdns = true; + ipv6 = true; + }; + systemd.services.avahi-daemon.wantedBy = lib.mkForce []; + systemd.timers.avahi-daemon = { + description = "Delayed startup of Avahi"; + wantedBy = [ "timers.target" ]; + timerConfig = { + OnActiveSec = "1 min"; + }; }; } -- cgit 1.4.1