2021-04-19 05:45:08 +03:00
|
|
|
{ lib }:
|
|
|
|
|
2021-04-26 02:21:40 +03:00
|
|
|
# dependencies to return a builder
|
|
|
|
{ self, inputs }:
|
2021-03-14 10:10:51 +03:00
|
|
|
|
2021-04-26 02:21:40 +03:00
|
|
|
{ modules, specialArgs, ... } @ args:
|
|
|
|
let inherit (specialArgs.channel.input.lib) nixosSystem; in
|
|
|
|
nixosSystem
|
|
|
|
(args // {
|
|
|
|
modules =
|
|
|
|
let
|
|
|
|
fullHostConfig = (nixosSystem (args // { inherit modules; })).config;
|
2021-03-18 23:58:01 +03:00
|
|
|
|
2021-04-26 02:21:40 +03:00
|
|
|
isoConfig = (nixosSystem
|
|
|
|
(args // {
|
|
|
|
modules = modules ++ [
|
|
|
|
(lib.modules.iso { inherit self inputs fullHostConfig; })
|
|
|
|
];
|
|
|
|
})).config;
|
|
|
|
|
|
|
|
hmConfig = (nixosSystem
|
|
|
|
(args // {
|
|
|
|
modules = modules ++ [
|
|
|
|
(lib.modules.hmConfig)
|
|
|
|
];
|
|
|
|
})).config;
|
|
|
|
in
|
|
|
|
modules ++ [{
|
|
|
|
system.build = {
|
|
|
|
iso = isoConfig.system.build.isoImage;
|
|
|
|
homes = hmConfig.home-manager.users;
|
|
|
|
};
|
|
|
|
lib = {
|
|
|
|
inherit specialArgs;
|
|
|
|
testModule = {
|
|
|
|
imports = modules;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
}];
|
|
|
|
})
|