summaryrefslogtreecommitdiffstats
path: root/glances/amps
diff options
context:
space:
mode:
authornicolargo <nicolas@nicolargo.com>2020-07-21 10:26:40 +0200
committernicolargo <nicolas@nicolargo.com>2020-07-21 10:26:40 +0200
commit05897a61dd0a1da366e2f27231cbf0df19bebfb2 (patch)
tree4d96683b0c9d208b37ff23e6fd55dae12c73cccd /glances/amps
parent219c4de08f240320cae96e0a5a4a082db45a06da (diff)
Enhancement Request: .conf parameter for AMP #1690
Diffstat (limited to 'glances/amps')
-rw-r--r--glances/amps/glances_amp.py7
1 files changed, 3 insertions, 4 deletions
diff --git a/glances/amps/glances_amp.py b/glances/amps/glances_amp.py
index 2ee89735..ccbee541 100644
--- a/glances/amps/glances_amp.py
+++ b/glances/amps/glances_amp.py
@@ -99,12 +99,11 @@ class GlancesAmp(object):
logger.debug("AMP - {}: Can not find section {} in the configuration file".format(self.NAME, self.amp_name))
return False
- # enable, regex and refresh are mandatories
- # if not configured then AMP is disabled
if self.enable():
- for k in ['regex', 'refresh']:
+ # Refresh option is mandatory
+ for k in ['refresh']:
if k not in self.configs:
- logger.warning("AMP - {}: Can not find configuration key {} in section {}".format(self.NAME, k, self.amp_name))
+ logger.warning("AMP - {}: Can not find configuration key {} in section {} (the AMP will be disabled)".format(self.NAME, k, self.amp_name))
self.configs['enable'] = 'false'
else:
logger.debug("AMP - {} is disabled".format(self.NAME))