Merge pull request #73049 from flokli/fix-redis-merge

nixos/redis: fix merging
This commit is contained in:
Florian Klink 2019-11-08 22:13:54 +01:00 committed by GitHub
commit cced569cac
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -185,10 +185,10 @@ in
###### implementation ###### implementation
config = mkIf config.services.redis.enable { config = mkIf config.services.redis.enable {
boot.kernel.sysctl = (mkMerge [
boot.kernel.sysctl = { { "vm.nr_hugepages" = "0"; }
"vm.nr_hugepages" = "0"; ( mkIf cfg.vmOverCommit { "vm.overcommit_memory" = "1"; } )
} // mkIf cfg.vmOverCommit { "vm.overcommit_memory" = "1"; }; ]);
networking.firewall = mkIf cfg.openFirewall { networking.firewall = mkIf cfg.openFirewall {
allowedTCPPorts = [ cfg.port ]; allowedTCPPorts = [ cfg.port ];