Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
48 lines
1.2 KiB
Nix
48 lines
1.2 KiB
Nix
{
|
|
config,
|
|
pkgs,
|
|
lib,
|
|
...
|
|
}:
|
|
let
|
|
cfg = config.services.hardware.deepcool-digital-linux;
|
|
in
|
|
{
|
|
meta.maintainers = [ lib.maintainers.NotAShelf ];
|
|
|
|
options.services.hardware.deepcool-digital-linux = {
|
|
enable = lib.mkEnableOption "DeepCool Digital monitoring daemon";
|
|
package = lib.mkPackageOption pkgs "deepcool-digital-linux" { };
|
|
|
|
extraArgs = lib.mkOption {
|
|
type = lib.types.listOf lib.types.str;
|
|
default = [ ];
|
|
example = lib.literalExpression ''
|
|
[
|
|
# Change the update interval
|
|
"--update 750"
|
|
# Enable the alarm
|
|
"--alarm"
|
|
]
|
|
'';
|
|
description = ''
|
|
Extra command line arguments to be passed to the deepcool-digital-linux daemon.
|
|
'';
|
|
};
|
|
};
|
|
|
|
config = lib.mkIf cfg.enable {
|
|
environment.systemPackages = [ cfg.package ];
|
|
systemd.services.deepcool-digital-linux = {
|
|
description = "DeepCool Digital";
|
|
wantedBy = [ "multi-user.target" ];
|
|
serviceConfig = {
|
|
StateDirectory = "deepcool-digital-linux";
|
|
WorkingDirectory = "/var/lib/deepcool-digital-linux";
|
|
ExecStart = "${lib.getExe cfg.package} ${lib.escapeShellArgs cfg.extraArgs}";
|
|
Restart = "always";
|
|
};
|
|
};
|
|
};
|
|
}
|