Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)

exhibitor: Fix bug with automatic instance management

Exhibitor tests the auto-manage-instances config value to see if it's a
non-zero integer, rather than a true/false string, which was getting
put into the config before. This now causes autoManageInstances to
behave correctly.

+4 -1
+4 -1
nixos/modules/services/misc/exhibitor.nix
··· 15 election-port=${toString cfg.zkElectionPort} 16 cleanup-period-ms=${toString cfg.zkCleanupPeriod} 17 servers-spec=${concatStringsSep "," cfg.zkServersSpec} 18 - auto-manage-instances=${lib.boolToString cfg.autoManageInstances} 19 ${cfg.extraConf} 20 ''; 21 configDir = pkgs.writeTextDir "exhibitor.properties" exhibitorConfig; 22 cliOptionsCommon = { 23 configtype = cfg.configType;
··· 15 election-port=${toString cfg.zkElectionPort} 16 cleanup-period-ms=${toString cfg.zkCleanupPeriod} 17 servers-spec=${concatStringsSep "," cfg.zkServersSpec} 18 + auto-manage-instances=${toString cfg.autoManageInstances} 19 ${cfg.extraConf} 20 ''; 21 + # NB: toString rather than lib.boolToString on cfg.autoManageInstances is intended. 22 + # Exhibitor tests if it's an integer not equal to 0, so the empty string (toString false) 23 + # will operate in the same fashion as a 0. 24 configDir = pkgs.writeTextDir "exhibitor.properties" exhibitorConfig; 25 cliOptionsCommon = { 26 configtype = cfg.configType;