extract systemConfiguration into its own output module

This commit is contained in:
Daniel Barlow
2024-12-19 20:55:10 +00:00
parent f9b4f0bc9c
commit 56c667cfd5
2 changed files with 29 additions and 10 deletions

View File

@@ -0,0 +1,28 @@
{
config
, pkgs
, lib
, ...
}:
let
inherit (lib) mkEnableOption mkOption mkIf types;
inherit (pkgs) runCommand;
in
{
options = {
system.outputs = {
systemConfiguration = mkOption {
type = types.package;
description = ''
pkgs.systemconfig for the configured filesystem,
contains 'activate' and 'init' commands
'';
internal = true;
};
};
};
config = {
system.outputs.systemConfiguration =
pkgs.systemconfig config.filesystem.contents;
};
}