From 2d50a76e993e8ffc66c8b8da820d6becd4b6677f Mon Sep 17 00:00:00 2001 From: Baitinq Date: Sat, 4 Feb 2023 17:00:59 +0100 Subject: Hosts: Use flake nixpkgs as system nixpkgs in nix-* cmds --- hosts/configuration.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/hosts/configuration.nix b/hosts/configuration.nix index 9759095..ec000b0 100644 --- a/hosts/configuration.nix +++ b/hosts/configuration.nix @@ -198,8 +198,12 @@ }; }; + # Needed for nix-* commands to use the system's nixpkgs + environment.etc."channels/nixpkgs".source = inputs.nixpkgs.outPath; + nix = { registry.nixpkgs.flake = inputs.nixpkgs; + nixPath = [ "nixpkgs=/etc/channels/nixpkgs" "nixos-config=/etc/nixos/configuration.nix" "/nix/var/nix/profiles/per-user/root/channels" ]; gc = { automatic = true; dates = "daily"; -- cgit 1.4.1