Merge pull request 'build-clan: move clan attribute relates modules into subfolder' (#4063) from clan-unify into main
Reviewed-on: https://git.clan.lol/clan/clan-core/pulls/4063
This commit is contained in:
@@ -90,7 +90,7 @@ in
|
||||
};
|
||||
|
||||
templates = lib.mkOption {
|
||||
type = types.submodule { imports = [ ./templates/interface.nix ]; };
|
||||
type = types.submodule { imports = [ ./templates.nix ]; };
|
||||
default = { };
|
||||
description = ''
|
||||
Define Clan templates.
|
||||
@@ -100,7 +100,7 @@ in
|
||||
inventory = lib.mkOption {
|
||||
type = types.submodule {
|
||||
imports = [
|
||||
(lib.modules.importApply ../inventory/build-inventory/interface.nix { inherit clanLib; })
|
||||
(lib.modules.importApply ../../inventory/build-inventory/interface.nix { inherit clanLib; })
|
||||
];
|
||||
};
|
||||
description = ''
|
||||
@@ -116,13 +116,13 @@ in
|
||||
Global information about the clan.
|
||||
'';
|
||||
type = types.deferredModuleWith {
|
||||
staticModules = [ ../inventory/build-inventory/meta-interface.nix ];
|
||||
staticModules = [ ../../inventory/build-inventory/meta-interface.nix ];
|
||||
};
|
||||
default = { };
|
||||
};
|
||||
|
||||
secrets = lib.mkOption {
|
||||
type = types.submodule { imports = [ ./secrets/interface.nix ]; };
|
||||
type = types.submodule { imports = [ ./secrets.nix ]; };
|
||||
description = ''
|
||||
Secrets related options such as AGE plugins required to encrypt/decrypt secrets using the CLI.
|
||||
'';
|
||||
@@ -120,7 +120,7 @@ let
|
||||
moduleSystemConstructor.${machineClasses.${name}} {
|
||||
modules = [
|
||||
(config.outputs.moduleForMachine.${name} or { })
|
||||
(lib.modules.importApply ./machineModules/overridePkgs.nix {
|
||||
(lib.modules.importApply ../machineModules/overridePkgs.nix {
|
||||
pkgs = pkgsFor.${system};
|
||||
})
|
||||
];
|
||||
@@ -201,7 +201,7 @@ in
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
(lib.modules.importApply ./machineModules/forName.nix {
|
||||
(lib.modules.importApply ../machineModules/forName.nix {
|
||||
inherit (config.inventory) meta;
|
||||
inherit
|
||||
name
|
||||
@@ -9,8 +9,8 @@
|
||||
{
|
||||
flakePartsModule = {
|
||||
imports = [
|
||||
(lib.modules.importApply ./interface.nix { inherit clanLib; })
|
||||
./module.nix
|
||||
(lib.modules.importApply ./clan/interface.nix { inherit clanLib; })
|
||||
./clan/module.nix
|
||||
];
|
||||
};
|
||||
|
||||
@@ -68,7 +68,7 @@
|
||||
imports = [
|
||||
rest
|
||||
# implementation
|
||||
./module.nix
|
||||
./clan/module.nix
|
||||
];
|
||||
};
|
||||
in
|
||||
|
||||
@@ -7,7 +7,7 @@ let
|
||||
eval = lib.evalModules {
|
||||
class = "nixos";
|
||||
modules = [
|
||||
(lib.modules.importApply ./interface.nix { inherit clanLib; })
|
||||
(lib.modules.importApply ./clan/interface.nix { inherit clanLib; })
|
||||
];
|
||||
};
|
||||
evalDocs = pkgs.nixosOptionsDoc {
|
||||
|
||||
@@ -18,7 +18,7 @@ module:
|
||||
;
|
||||
};
|
||||
modules = [
|
||||
(lib.modules.importApply ./interface.nix { inherit (clan-core) clanLib; })
|
||||
(lib.modules.importApply ./clan/interface.nix { inherit (clan-core) clanLib; })
|
||||
module
|
||||
{
|
||||
inherit specialArgs;
|
||||
|
||||
@@ -23,7 +23,7 @@ in
|
||||
let
|
||||
config = buildClan {
|
||||
meta.name = "test";
|
||||
imports = [ ./module.nix ];
|
||||
imports = [ ./clan/module.nix ];
|
||||
};
|
||||
in
|
||||
{
|
||||
@@ -42,7 +42,7 @@ in
|
||||
outPath = ./.;
|
||||
};
|
||||
meta.name = "test";
|
||||
imports = [ ./module.nix ];
|
||||
imports = [ ./clan/module.nix ];
|
||||
};
|
||||
in
|
||||
{
|
||||
@@ -82,7 +82,7 @@ in
|
||||
inventory.meta.name = "test";
|
||||
}
|
||||
|
||||
./module.nix
|
||||
./clan/module.nix
|
||||
# Explicit output, usually defined by flake-parts
|
||||
{ options.nixosConfigurations = lib.mkOption { type = lib.types.raw; }; }
|
||||
];
|
||||
|
||||
Reference in New Issue
Block a user