chef-prometheus-exporters icon indicating copy to clipboard operation
chef-prometheus-exporters copied to clipboard

syntax error when disabling a collector thats in the default enabled array

Open ayanich opened this issue 6 years ago • 1 comments

Because this cookbook sets an explicit set of collectors that are enabled and passed to the command line, https://github.com/evilmartians/chef-prometheus-exporters/blob/098a02d869488a9908289103c7567da31504e371/attributes/node.rb#L11, if you add one of these to the collectors_disabled array for the node exporter, you will end up with a command line that both enables and disables the collector which is a syntax error. To work around I am doing node.default['prometheus_exporters']['node']['collectors_enabled'] = []

ayanich avatar Oct 30 '18 00:10 ayanich

@ayanich do you have any suggestions on how to resolve the issue? I can make the disabling array to have the higher precedence level for example.

dragonsmith avatar Feb 03 '19 15:02 dragonsmith