Merge pull request #2283 from wizeman/u/sysctl-merge
nixos: Fix sysctl option merging
This commit is contained in:
commit
f2e9ebbd46
@ -6,8 +6,12 @@ let
|
|||||||
|
|
||||||
sysctlOption = mkOptionType {
|
sysctlOption = mkOptionType {
|
||||||
name = "sysctl option value";
|
name = "sysctl option value";
|
||||||
check = x: isBool x || isString x || isInt x || isNull x;
|
check = val:
|
||||||
merge = args: defs: (last defs).value; # FIXME: hacky way to allow overriding in configuration.nix.
|
let
|
||||||
|
checkType = x: isBool x || isString x || isInt x || isNull x;
|
||||||
|
in
|
||||||
|
checkType val || (val._type or "" == "override" && checkType val.content);
|
||||||
|
merge = loc: defs: mergeOneOption loc (filterOverrides defs);
|
||||||
};
|
};
|
||||||
|
|
||||||
in
|
in
|
||||||
|
Loading…
x
Reference in New Issue
Block a user