forked from DGNum/liminix
28 lines
591 B
Nix
28 lines
591 B
Nix
|
{
|
||
|
pkgs,
|
||
|
lib,
|
||
|
utils
|
||
|
}:
|
||
|
let
|
||
|
inherit (utils.systemdUtils.lib) serviceConfig unitConfig;
|
||
|
inherit (utils.systemdUtils.unitOptions) stage2ServiceOptions;
|
||
|
stage2ServiceConfig = {
|
||
|
imports = [ serviceConfig ];
|
||
|
# Default path for systemd services. Should be quite minimal.
|
||
|
config.path = lib.mkAfter [
|
||
|
pkgs.coreutils
|
||
|
# pkgs.gnugrep
|
||
|
# pkgs.gnused
|
||
|
pkgs.systemd
|
||
|
];
|
||
|
};
|
||
|
in
|
||
|
{
|
||
|
inherit (utils.systemdUtils.types) units targets;
|
||
|
services = lib.types.attrsOf (lib.types.submodule [
|
||
|
unitConfig
|
||
|
stage2ServiceOptions
|
||
|
stage2ServiceConfig
|
||
|
]);
|
||
|
}
|