From eb92294f514568445b134f3fb9154c4d55f0519f Mon Sep 17 00:00:00 2001 From: Alan Pearce Date: Sun, 17 Sep 2017 20:30:05 +0200 Subject: nix: Allow auto-upgrading with unstable packages --- modules/nix.nix | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'modules') diff --git a/modules/nix.nix b/modules/nix.nix index e5353de..e1f1e16 100644 --- a/modules/nix.nix +++ b/modules/nix.nix @@ -18,7 +18,10 @@ system.autoUpgrade = { enable = true; }; - systemd.services.nixos-upgrade.script = '' - ${config.system.build.nixos-rebuild}/bin/nixos-rebuild boot ${toString config.system.autoUpgrade.flags} - ''; + systemd.services.nixos-upgrade = { + environment.NIXPKGS_ALLOW_UNFREE = "1"; + script = '' + ${config.system.build.nixos-rebuild}/bin/nixos-rebuild boot ${toString config.system.autoUpgrade.flags} + ''; + }; } -- cgit 1.4.1