flake.nix: define pkgs in flake

Set the global package set via `hosts/default.nix` passed in from its
definition in `flake.nix`.
This commit is contained in:
Timothy DeHerrera 2020-01-29 08:50:07 -07:00
parent 331fa795b1
commit d5ba9f6173
No known key found for this signature in database
GPG Key ID: 8985725DB5B0C122
3 changed files with 11 additions and 10 deletions

View File

@ -6,18 +6,21 @@
inputs.nixpkgs.url = "github:nrdxp/nixpkgs/fork";
inputs.home.url = "github:nrdxp/home-manager/flakes";
outputs = args@{ self, home, nixpkgs }:
outputs = inputs@{ self, home, nixpkgs }:
let
inherit (builtins) listToAttrs baseNameOf attrNames readDir;
inherit (nixpkgs.lib) removeSuffix;
system = "x86_64-linux";
pkgs = import nixpkgs {
system = "x86_64-linux";
inherit system;
overlays = self.overlays;
config = { allowUnfree = true; };
};
in {
nixosConfigurations = let configs = import ./hosts args;
in {
nixosConfigurations =
let configs = import ./hosts (inputs // { inherit system pkgs; });
in configs;
overlay = import ./pkgs;

View File

@ -1,4 +1,4 @@
args@{ home, nixpkgs, self, ... }:
inputs@{ home, nixpkgs, self, pkgs, system, ... }:
let
inherit (nixpkgs) lib;
@ -10,7 +10,7 @@ let
config = hostName:
lib.nixosSystem rec {
system = "x86_64-linux";
inherit system;
specialArgs.usr = { inherit utils; };
@ -29,7 +29,7 @@ let
system.configurationRevision = self.rev;
nixpkgs.overlays = self.overlays;
nixpkgs = { inherit pkgs; };
};
local = import "${toString ./.}/${hostName}.nix";

View File

@ -119,8 +119,6 @@ in {
};
nixpkgs.config.allowUnfree = true;
security = {
hideProcessInformation = true;