]> arthur.barton.de Git - netdata.git/commitdiff
allows multiple versions of charts.d.plugin to have their configurations in different...
authorCosta Tsaousis (ktsaou) <costa@tsaousis.gr>
Mon, 17 Oct 2016 23:14:26 +0000 (02:14 +0300)
committerCosta Tsaousis (ktsaou) <costa@tsaousis.gr>
Mon, 17 Oct 2016 23:14:26 +0000 (02:14 +0300)
plugins.d/charts.d.plugin

index df9998ecec1ab838caba4c9c743b9b35efe8d46a..a21f3cac30314616c1375e75ff37546759d5b41e 100755 (executable)
@@ -397,16 +397,16 @@ do
     [ $debug -eq 1 ] && echo >&2 "$PROGRAM_NAME: loading chart: '$chartsd/$chart.chart.sh'"
     . "$chartsd/$chart.chart.sh"
 
-    if [ -f "$confd/charts.d/$chart.conf" ]
+    if [ -f "$confd/$PROGRAM_NAME/$chart.conf" ]
     then
-        [ $debug -eq 1 ] && echo >&2 "$PROGRAM_NAME: loading chart options: '$confd/charts.d/$chart.conf'"
-        . "$confd/charts.d/$chart.conf"
+        [ $debug -eq 1 ] && echo >&2 "$PROGRAM_NAME: loading chart options: '$confd/$PROGRAM_NAME/$chart.conf'"
+        . "$confd/$PROGRAM_NAME/$chart.conf"
     elif [ -f "$confd/$chart.conf" ]
     then
         [ $debug -eq 1 ] && echo >&2 "$PROGRAM_NAME: loading chart options: '$confd/$chart.conf'"
         . "$confd/$chart.conf"
     else
-        echo >&2 "$PROGRAM_NAME: $chart: configuration file '$confd/charts.d/$chart.conf' not found. Using defaults."
+        echo >&2 "$PROGRAM_NAME: $chart: configuration file '$confd/$PROGRAM_NAME/$chart.conf' not found. Using defaults."
     fi
 
     eval "dt=\$$chart$suffix_update_every"