Module: check_mk
Branch: master
Commit: 70723cf316e3d80b54238a9fa4ed8a096c43fa3b
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=70723cf316e3d8…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Mon Apr 16 10:19:17 2012 +0200
WATO API: Added new method rewrite_configuration to trigger a rewrite of
all host related wato configuration files to distribute changed tags
---
ChangeLog | 2 ++
web/htdocs/wato.py | 5 +++++
2 files changed, 7 insertions(+), 0 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index 735d39b..1423343 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -19,6 +19,8 @@
handling of users only appearing in htpasswd configurable. The default
is set to True to keep the default behaviour. Users only appearing in
htpasswd will not be shown in this GUI when the option is set to False.
+ * WATO API: Added new method rewrite_configuration to trigger a rewrite of
+ all host related wato configuration files to distribute changed tags
Multisite
* Added config option default_ts_format to configure default timestamp
diff --git a/web/htdocs/wato.py b/web/htdocs/wato.py
index 6c7a67d..57fdd2b 100644
--- a/web/htdocs/wato.py
+++ b/web/htdocs/wato.py
@@ -10200,6 +10200,11 @@ class API:
save_folder_and_hosts(folder)
return folder[".hosts"][host["name"]]
+ # Rewrite the WATO configuration files
+ def rewrite_configuration(self):
+ self.prepare_folder_info()
+ rewrite_config_files_below(g_root_folder)
+
# Return displayable information about host (call with result of get_host())
def get_host_painted(self, host):
result = []