expose modulesPath to ease out-of-tree configuration.nix

This commit is contained in:
Daniel Barlow 2024-03-17 19:03:44 +00:00
parent 98318b450d
commit 4ea518e296
2 changed files with 6 additions and 2 deletions

View file

@ -20,6 +20,9 @@ let
}); });
eval = pkgs.lib.evalModules { eval = pkgs.lib.evalModules {
specialArgs = {
modulesPath = builtins.toString ./modules;
};
modules = [ modules = [
{ _module.args = { inherit pkgs; inherit (pkgs) lim; }; } { _module.args = { inherit pkgs; inherit (pkgs) lim; }; }
./modules/hardware.nix ./modules/hardware.nix

View file

@ -8,6 +8,7 @@
config, config,
pkgs, pkgs,
lib, lib,
modulesPath,
... ...
}: let }: let
secrets = import ./extneder-secrets.nix; secrets = import ./extneder-secrets.nix;
@ -20,8 +21,8 @@ in rec {
}; };
imports = [ imports = [
../modules/profiles/wap.nix "${modulesPath}/profiles/wap.nix"
../modules/vlan "${modulesPath}/vlan"
]; ];
hostname = "extneder"; hostname = "extneder";