This is an automated email from the git hooks/post-receive script. New commit to branch develop in repository mum. See http://git.chorem.org/mum.git commit 996699e0c14e4e9f2732dfde0d1cb188641eac92 Author: Alexis Guilbaud <guilbaud@codelutin.com> Date: Fri Apr 3 17:33:26 2015 +0200 shelve: corrected config_mod_activation => activating a module for the 1st time adds an instruction for process_monitoring + hostpage: non activated module line on table is not shown --- app/modules/storage_modules/shelve_db.py | 8 ++++++++ views/hostpage.html | 4 +++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/app/modules/storage_modules/shelve_db.py b/app/modules/storage_modules/shelve_db.py index 160a48f..e659ad6 100644 --- a/app/modules/storage_modules/shelve_db.py +++ b/app/modules/storage_modules/shelve_db.py @@ -526,6 +526,14 @@ class shelve_db: # we copy the global configuration of this module on the host configuration self.db["hosts"][addr_host]["conf"]["monitoring"][mod_name] = self.db['global_conf'][mod_name] self.db["hosts"][addr_host]["conf"]["monitoring"][mod_name]['activated'] = args['activated'][mod_name] + # we now add an instruction on the monitoring list + add_instr = {} + add_instr['addr'] = addr_host + add_instr['os'] = json.loads(self.db['hosts'][addr_host]['detected']['nmap'])['os'] + add_instr['mod_name'] = mod_name + add_instr['time'] = datetime.now() + add_instr['freq'] = self.db['hosts'][addr_host]['conf']['monitoring'][mod_name]['check_frequency'] + dict_instr['add'].append(add_instr) elif not self.db["hosts"][addr_host]["conf"]["monitoring"][mod_name]["activated"] == \ args['activated'][mod_name]: # second case, the configuration module have changed diff --git a/views/hostpage.html b/views/hostpage.html index 189dc14..cee03c9 100644 --- a/views/hostpage.html +++ b/views/hostpage.html @@ -20,7 +20,9 @@ </thead> <tbody> - <tr ng-repeat="(itemname, item) in items.monitoring" class={{item.state}}> + <tr ng-repeat="(itemname, item) in items.monitoring" + class={{item.state}} + ng-show="items.activated_monitoring[itemname]"> <td>{{itemname}}</td> <td>{{item.value}}</td> <td>{{item.state}}</td> -- To stop receiving notification emails like this one, please contact chorem.org SCM administrator <admin+scm@chorem.org>.