From 27b6b78f8ddb58444d3ef778a5bb2019c032a0eb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jes=C3=BAs=20=C3=81ngel?= Date: Thu, 23 Aug 2018 10:40:01 +0200 Subject: [PATCH] Renamed configuration for monitoring --- config.yml | 7 ++++--- server/monitoring.js | 8 ++++---- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/config.yml b/config.yml index 99108c324..401de8fc7 100644 --- a/config.yml +++ b/config.yml @@ -56,13 +56,11 @@ # # ------------------------------ Advanced indices ------------------------------ # -# Configure .wazuh, .wazuh-version, wazuh-monitoring-3.x-* indices shards and replicas. +# Configure .wazuh and .wazuh-version indices shards and replicas. #wazuh.shards : 1 #wazuh.replicas : 1 #wazuh-version.shards : 1 #wazuh-version.replicas: 1 -#wazuh-monitoring.shards: 5 -#wazuh-monitoring.replicas: 1 # # --------------------------- Index pattern selector --------------------------- # @@ -90,3 +88,6 @@ # Default: 3600 (s) #wazuh.monitoring.frequency: 3600 # +# Configure wazuh-monitoring-3.x-* indices shards and replicas. +#wazuh.monitoring.shards: 5 +#wazuh.monitoring.replicas: 1 diff --git a/server/monitoring.js b/server/monitoring.js index 3743f9137..0b78a8db0 100644 --- a/server/monitoring.js +++ b/server/monitoring.js @@ -236,11 +236,11 @@ export default (server, options) => { if(!ENABLED) return; const configFile = getConfiguration(); - const shards = configFile && typeof configFile["wazuh-monitoring.shards"] !== 'undefined' ? - configFile["wazuh-monitoring.shards"] : 5; + const shards = configFile && typeof configFile['wazuh.monitoring.shards'] !== 'undefined' ? + configFile['wazuh.monitoring.shards'] : 5; - const replicas = configFile && typeof configFile["wazuh-monitoring.replicas"] !== 'undefined' ? - configFile["wazuh-monitoring.replicas"] : 1; + const replicas = configFile && typeof configFile['wazuh.monitoring.replicas'] !== 'undefined' ? + configFile['wazuh.monitoring.replicas'] : 1; const configuration = { settings: {