modules/tlp: Make optional via custom options
This commit is contained in:
parent
339e7c4e9d
commit
c23775319c
|
@ -5,4 +5,10 @@ options.my.highDPI = lib.mkOption {
|
||||||
default = true;
|
default = true;
|
||||||
type = lib.types.bool;
|
type = lib.types.bool;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
options.my.includeTLP = lib.mkOption {
|
||||||
|
description = "If the device should get TLP";
|
||||||
|
default = true;
|
||||||
|
type = lib.types.bool;
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
|
{lib, config, ...}:
|
||||||
{
|
{
|
||||||
services.tlp = {
|
services.tlp = lib.mkIf config.my.includeTLP {
|
||||||
enable = true;
|
enable = true;
|
||||||
settings = {
|
settings = {
|
||||||
TLP_DEFAULT_MODE = "AC";
|
TLP_DEFAULT_MODE = "AC";
|
||||||
|
|
Loading…
Reference in a new issue