Make Nagios an optional feature
Now that Sensu is the recommended backend for alerting, it should be
possible to deploy StackLight without Nagios. Unfortunately the current
aggregator and metric_collector classes have a hard dependency on Nagios
and this change fixes it.
Note that user models already using Nagios and willing to stick with it
should now include heka.metric_collector.output.nagios and
heka.aggregator.output.nagios classes wherever needed.
diff --git a/heka/aggregator/cluster.yml b/heka/aggregator/cluster.yml
index 2913211..1d1e5c7 100644
--- a/heka/aggregator/cluster.yml
+++ b/heka/aggregator/cluster.yml
@@ -2,9 +2,6 @@
- service.heka.aggregator.cluster
- system.heka.server
parameters:
- _param:
- nagios_default_host_alarm_clusters: 00-clusters
- nagios_host_dimension_key: nagios_host
heka:
aggregator:
influxdb_host: ${_param:heka_influxdb_host}
@@ -12,12 +9,6 @@
influxdb_database: lma
influxdb_username: lma
influxdb_password: ${_param:influxdb_stacklight_password}
- nagios_host: ${_param:nagios_host}
- nagios_username: ${_param:nagios_username}
- nagios_password: ${_param:nagios_password}
- nagios_port: ${_param:nagios_status_port}
- nagios_default_host_alarm_clusters: ${_param:nagios_default_host_alarm_clusters}
- nagios_host_dimension_key: ${_param:nagios_host_dimension_key}
poolsize: 200
keepalived:
cluster:
diff --git a/heka/aggregator/single.yml b/heka/aggregator/single.yml
index c5ad6ab..5ee3605 100644
--- a/heka/aggregator/single.yml
+++ b/heka/aggregator/single.yml
@@ -2,9 +2,6 @@
- service.heka.aggregator.single
- system.heka.server
parameters:
- _param:
- nagios_default_host_alarm_clusters: 00-clusters
- nagios_host_dimension_key: nagios_host
heka:
aggregator:
influxdb_host: ${_param:heka_influxdb_host}
@@ -12,10 +9,4 @@
influxdb_database: lma
influxdb_username: lma
influxdb_password: ${_param:influxdb_stacklight_password}
- nagios_host: ${_param:nagios_host}
- nagios_username: ${_param:nagios_username}
- nagios_password: ${_param:nagios_password}
- nagios_port: ${_param:nagios_status_port}
- nagios_default_host_alarm_clusters: ${_param:nagios_default_host_alarm_clusters}
- nagios_host_dimension_key: ${_param:nagios_host_dimension_key}
poolsize: 200
diff --git a/heka/metric_collector/output/nagios.yml b/heka/metric_collector/output/nagios.yml
new file mode 100644
index 0000000..89d981f
--- /dev/null
+++ b/heka/metric_collector/output/nagios.yml
@@ -0,0 +1,2 @@
+classes:
+- service.heka.metric_collector.output.nagios
diff --git a/heka/metric_collector/output/sensu.yml b/heka/metric_collector/output/sensu.yml
index 3143fd9..a68a2ab 100644
--- a/heka/metric_collector/output/sensu.yml
+++ b/heka/metric_collector/output/sensu.yml
@@ -1,3 +1,2 @@
classes:
- service.heka.metric_collector.output.sensu
-
diff --git a/heka/metric_collector/single.yml b/heka/metric_collector/single.yml
index 443a4e9..b4167f0 100644
--- a/heka/metric_collector/single.yml
+++ b/heka/metric_collector/single.yml
@@ -12,7 +12,3 @@
influxdb_port: 8086
influxdb_time_precision: ms
influxdb_username: lma
- nagios_host: ${_param:nagios_host}
- nagios_username: ${_param:nagios_username}
- nagios_password: ${_param:nagios_password}
- nagios_port: ${_param:nagios_status_port}