@cryptotaxi247 / netdata-1 / commits / cb2d5267a

allows multiple versions of charts.d.plugin to have their configurations in different directories

Costa Tsaousis (ktsaou) committed Oct 18, 2016 at 02:14 UTC cb2d5267a2176f952f19537ad7379f4f1a9469d0
1 file changed +4 -4
plugins.d/charts.d.plugin
+4 -4
@@ -397,16 +397,16 @@ do
397 [ $debug -eq 1 ] && echo >&2 "$PROGRAM_NAME: loading chart: '$chartsd/$chart.chart.sh'"
398 . "$chartsd/$chart.chart.sh"
399
400 - if [ -f "$confd/charts.d/$chart.conf" ]
400 + if [ -f "$confd/$PROGRAM_NAME/$chart.conf" ]
401 then
402 - [ $debug -eq 1 ] && echo >&2 "$PROGRAM_NAME: loading chart options: '$confd/charts.d/$chart.conf'"
403 - . "$confd/charts.d/$chart.conf"
402 + [ $debug -eq 1 ] && echo >&2 "$PROGRAM_NAME: loading chart options: '$confd/$PROGRAM_NAME/$chart.conf'"
403 + . "$confd/$PROGRAM_NAME/$chart.conf"
404 elif [ -f "$confd/$chart.conf" ]
405 then
406 [ $debug -eq 1 ] && echo >&2 "$PROGRAM_NAME: loading chart options: '$confd/$chart.conf'"
407 . "$confd/$chart.conf"
408 else
409 - echo >&2 "$PROGRAM_NAME: $chart: configuration file '$confd/charts.d/$chart.conf' not found. Using defaults."
409 + echo >&2 "$PROGRAM_NAME: $chart: configuration file '$confd/$PROGRAM_NAME/$chart.conf' not found. Using defaults."
410 fi
411
412 eval "dt=\$$chart$suffix_update_every"