2017-02-26 14:50:01 +00:00
|
|
|
{ config, lib, pkgs, ... }:
|
|
|
|
{
|
2024-08-24 20:05:28 +00:00
|
|
|
meta.maintainers = with lib.maintainers; [ grahamc ];
|
2017-02-26 14:50:01 +00:00
|
|
|
options = {
|
|
|
|
|
|
|
|
hardware.mcelog = {
|
2024-08-24 20:05:28 +00:00
|
|
|
enable = lib.mkOption {
|
|
|
|
type = lib.types.bool;
|
2017-02-26 14:50:01 +00:00
|
|
|
default = false;
|
|
|
|
description = ''
|
|
|
|
Enable the Machine Check Exception logger.
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
};
|
|
|
|
|
2024-08-24 20:05:28 +00:00
|
|
|
config = lib.mkIf config.hardware.mcelog.enable {
|
2017-07-27 05:03:36 +00:00
|
|
|
systemd = {
|
|
|
|
packages = [ pkgs.mcelog ];
|
|
|
|
|
|
|
|
services.mcelog = {
|
|
|
|
wantedBy = [ "multi-user.target" ];
|
|
|
|
serviceConfig = {
|
|
|
|
ProtectHome = true;
|
|
|
|
PrivateNetwork = true;
|
|
|
|
PrivateTmp = true;
|
|
|
|
};
|
2017-02-26 14:50:01 +00:00
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|