From 3ab45f4b369c9c741b55ddedeaac4c797dc61c04 Mon Sep 17 00:00:00 2001 From: Franz Pletz Date: Tue, 11 Apr 2017 18:08:51 +0200 Subject: treewide: use boolToString function --- nixos/modules/services/logging/graylog.nix | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'nixos/modules/services/logging') diff --git a/nixos/modules/services/logging/graylog.nix b/nixos/modules/services/logging/graylog.nix index 95283096662e..9f0fb11f0252 100644 --- a/nixos/modules/services/logging/graylog.nix +++ b/nixos/modules/services/logging/graylog.nix @@ -4,16 +4,15 @@ with lib; let cfg = config.services.graylog; - configBool = b: if b then "true" else "false"; confFile = pkgs.writeText "graylog.conf" '' - is_master = ${configBool cfg.isMaster} + is_master = ${boolToString cfg.isMaster} node_id_file = ${cfg.nodeIdFile} password_secret = ${cfg.passwordSecret} root_username = ${cfg.rootUsername} root_password_sha2 = ${cfg.rootPasswordSha2} elasticsearch_cluster_name = ${cfg.elasticsearchClusterName} - elasticsearch_discovery_zen_ping_multicast_enabled = ${configBool cfg.elasticsearchDiscoveryZenPingMulticastEnabled} + elasticsearch_discovery_zen_ping_multicast_enabled = ${boolToString cfg.elasticsearchDiscoveryZenPingMulticastEnabled} elasticsearch_discovery_zen_ping_unicast_hosts = ${cfg.elasticsearchDiscoveryZenPingUnicastHosts} message_journal_dir = ${cfg.messageJournalDir} mongodb_uri = ${cfg.mongodbUri} -- cgit 1.4.1