]> arthur.barton.de Git - netdata.git/commitdiff
information about `enabled: no` in `python.d.conf`
authorpaulfantom <paulfantom@gmail.com>
Tue, 21 Jun 2016 11:13:35 +0000 (13:13 +0200)
committerpaulfantom <paulfantom@gmail.com>
Tue, 21 Jun 2016 11:13:35 +0000 (13:13 +0200)
conf.d/python.d.conf
plugins.d/python.d.plugin

index b467221116534cd753dbfae008c03284c0345ee0..e8f6e8923dba67b4c3bd48d06f076f45dbc23120 100644 (file)
@@ -1,5 +1,8 @@
 # This is the configuration for python.d.plugin
 
+# Disable all python modules
+enabled: no
+
 # By default python.d.plugin enables all modules stored in python.d
 # Modules can be disabled with setting "module_name = no"
 example: no
index cbbcf9ea1d788455faaf28c2568818d1fe99affd..5c6a55c21e42c37bf96aa44077662d897050d7ef 100755 (executable)
@@ -117,7 +117,6 @@ class PythonCharts(object):
                  modules_configs='../conf.d/',
                  modules_disabled=None):
         """
-        :param update_every: int
         :param modules: list
         :param modules_path: str
         :param modules_configs: str
@@ -532,8 +531,8 @@ def run():
     conf = read_config(configfile)
     if conf is not None:
         try:
-            # exit the whole plugin when 'enable: no' is set in 'python.d.conf'
-            if str(conf['enable']) is False:
+            # exit the whole plugin when 'enabled: no' is set in 'python.d.conf'
+            if str(conf['enabled']) is False:
                 fatal('disabled in configuration file.\n')
         except (KeyError, TypeError):
             pass
@@ -560,6 +559,7 @@ def run():
          ", ONLY_MODULES=" + str(modules))
 
     # run plugins
+    modules = ['phpfpm']
     charts = PythonCharts(modules, MODULES_DIR, CONFIG_DIR + "python.d/", disabled)
     charts.check()
     charts.create()