Module: check_mk
Branch: master
Commit: 474ecbc0df7594b843ffadde11e591d6857a924f
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=474ecbc0df7594…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Tue Dec 6 15:04:22 2016 +0100
4133 FIX Do not suppress site specific global issues during WATO activation
---
.werks/4133 | 9 +++++++++
ChangeLog | 1 +
web/htdocs/watolib.py | 20 +++++++++-----------
3 files changed, 19 insertions(+), 11 deletions(-)
diff --git a/.werks/4133 b/.werks/4133
new file mode 100644
index 0000000..e08b8c2
--- /dev/null
+++ b/.werks/4133
@@ -0,0 +1,9 @@
+Title: Do not suppress site specific global issues during WATO activation
+Level: 1
+Component: wato
+Compatible: compat
+Version: 1.4.0i3
+Date: 1481033046
+Class: fix
+
+
diff --git a/ChangeLog b/ChangeLog
index ecab0b5..8f74116 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -86,6 +86,7 @@
* 4084 FIX: Improved error handling in case of broken hosts.mk files
* 4130 FIX: Improved error handling when trying to edit not existant rules
* 4131 FIX: Fixed broken WATO site login when using password containing special
characters...
+ * 4133 FIX: Do not suppress site specific global issues during WATO activation
Notifications:
* 4042 FIX: Fix missing From address in synchronous SMTP notifications...
diff --git a/web/htdocs/watolib.py b/web/htdocs/watolib.py
index bb514b4..cf73164 100644
--- a/web/htdocs/watolib.py
+++ b/web/htdocs/watolib.py
@@ -3658,11 +3658,6 @@ def automation_push_snapshot():
multitar.extract_from_buffer(tarcontent, replication_paths)
- # We expect one file containing sitespecific global settings.
- # That is contained in the sub-tarball "sitespecific.tar" and
- # just contains one file: "sitespecific.mk". The contains a repr()
- # of all global settings, that should override the ones in global.mk
- # in various directories.
try:
tmp_dir = cmk.paths.tmp_dir + "/sitespecific-%s" % id(html)
if not os.path.exists(tmp_dir):
@@ -3676,15 +3671,18 @@ def automation_push_snapshot():
save_configuration_settings(current_settings)
shutil.rmtree(tmp_dir)
- except Exception, e:
- logger(LOG_WARNING, "Warning: cannot extract site-specific global settings:
%s" % e)
- confirm_all_local_changes() # pending changes are lost
+ confirm_all_local_changes() # pending changes are lost
+
+ call_hook_snapshot_pushed()
- call_hook_snapshot_pushed()
+ # Create rule making this site only monitor our hosts
+ create_distributed_wato_file(site_id)
+ except Exception, e:
+ raise MKGeneralException(_("Failed to deploy configuration:
\"%s\". "
+ "Please note that the site configuration has been
synchronized "
+ "partially.") % traceback.format_exc())
- # Create rule making this site only monitor our hosts
- create_distributed_wato_file(site_id)
log_audit(None, "replication", _("Synchronized with master (my site id
is %s.)") % site_id)
return True