Add Warning message if a [monitor] section is detected in the Glances configuration file

This commit is contained in:
Nicolargo
2016-09-01 15:29:36 +02:00
parent d6ada6b20f
commit e3076a6e2b

View File

@@ -56,6 +56,10 @@ class AmpsList(object):
if self.config is None:
return False
# Display a warning (deprecated) message if the monitor section exist
if "monitor" in self.config.sections():
logger.warning("A deprecated [monitor] section exists in the Glances configuration file. You should use the new Applications Monitoring Process module instead (http://glances.readthedocs.io/en/develop/aoa/amps.html).")
header = "glances_"
# For each AMP scrip, call the load_config method
for s in self.config.sections():