Module: check_mk
Branch: master
Commit: 6d9ec7b339928fb0ca8bff7e7f2edae4ba0e3cd9
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=6d9ec7b339928f…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Thu Dec 18 09:23:32 2014 +0100
#1771 FIX domino_mailqueues: Fixed exception during inventory when no data usable data available
---
.werks/1771 | 10 ++++++++++
ChangeLog | 1 +
checks/domino_mailqueues | 7 ++++---
3 files changed, 15 insertions(+), 3 deletions(-)
diff --git a/.werks/1771 b/.werks/1771
new file mode 100644
index 0000000..239e5c9
--- /dev/null
+++ b/.werks/1771
@@ -0,0 +1,10 @@
+Title: domino_mailqueues: Fixed exception during inventory when no data usable data available
+Level: 1
+Component: checks
+Class: fix
+Compatible: compat
+State: unknown
+Version: 1.2.7i1
+Date: 1418890967
+
+
diff --git a/ChangeLog b/ChangeLog
index e8375f2..5f5e4df 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -24,6 +24,7 @@
* 1768 FIX: brocade_fcport/brocade_info: Only try to discover these services when device provides correct info...
* 1769 FIX: megaraid_bbu: Fixed exception for some controllers reporting "full charge capacity"
* 1770 FIX: megaraid_pdisks: Now handling unconfigured good/bad states...
+ * 1771 FIX: domino_mailqueues: Fixed exception during inventory when no data usable data available
Multisite:
* 1758 Improved exception hander: Shows details without additional debug request, added mailto link for error report...
diff --git a/checks/domino_mailqueues b/checks/domino_mailqueues
index b098acb..0d41caa 100644
--- a/checks/domino_mailqueues
+++ b/checks/domino_mailqueues
@@ -38,9 +38,10 @@ domino_mailqueues = {
def inventory_domino_mailqueues(info):
for line in info:
- val = int(line[0][0].split(".")[12])
- if val in domino_mailqueues.keys():
- yield domino_mailqueues[val][0], {}
+ if line:
+ val = int(line[0][0].split(".")[12])
+ if val in domino_mailqueues.keys():
+ yield domino_mailqueues[val][0], {}
def check_domino_mailqueues(item, params, info):
for line in info:
Module: check_mk
Branch: master
Commit: 0914b07a2a7e38e7ffa31329c1dad2647a77ccda
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=0914b07a2a7e38…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Wed Dec 17 16:23:16 2014 +0100
#1788 New personal setting for start page, right after login
A user can now configure an alternative start URL in his personal
settings. Default is <tt>dashboard.py</tt> (which can changed in the
global setting). Only relative URLs are allowed.
---
.werks/1788 | 12 ++++++++++++
ChangeLog | 1 +
web/htdocs/main.py | 5 +++--
web/htdocs/sidebar.py | 2 +-
web/plugins/userdb/user_attributes.py | 10 ++++++++++
5 files changed, 27 insertions(+), 3 deletions(-)
diff --git a/.werks/1788 b/.werks/1788
new file mode 100644
index 0000000..5d6fd21
--- /dev/null
+++ b/.werks/1788
@@ -0,0 +1,12 @@
+Title: New personal setting for start page, right after login
+Level: 2
+Component: multisite
+Class: feature
+Compatible: compat
+State: unknown
+Version: 1.2.7i1
+Date: 1418829739
+
+A user can now configure an alternative start URL in his personal
+settings. Default is <tt>dashboard.py</tt> (which can changed in the
+global setting). Only relative URLs are allowed.
diff --git a/ChangeLog b/ChangeLog
index 3a4744a..1f8831a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -25,6 +25,7 @@
Multisite:
* 1758 Improved exception hander: Shows details without additional debug request, added mailto link for error report...
+ * 1788 New personal setting for start page, right after login...
* 1781 FIX: Fix broken grouping by host/service group in availability
* 1783 FIX: Finish the view "History of Scheduled Downtimes"...
* 1206 FIX: Hostname not longer shown as column in host views
diff --git a/web/htdocs/main.py b/web/htdocs/main.py
index 85fc2e4..89091f9 100644
--- a/web/htdocs/main.py
+++ b/web/htdocs/main.py
@@ -27,11 +27,12 @@
import defaults, config
def page_index():
- start_url = html.var("start_url", config.start_url)
+ default_start_url = config.user.get("start_url") or config.start_url
+ start_url = html.var("start_url", default_start_url)
# Prevent redirecting to absolute URL which could be used to redirect
# users to compromised pages
if '://' in start_url:
- start_url = config.start_url
+ start_url = default_start_url
# Do not cache the index page -> caching problems when page is accessed
# while not logged in
diff --git a/web/htdocs/sidebar.py b/web/htdocs/sidebar.py
index 132e0f0..793dac0 100644
--- a/web/htdocs/sidebar.py
+++ b/web/htdocs/sidebar.py
@@ -158,7 +158,7 @@ def sidebar_head():
html.write('<a title="%s" target="main" href="%s">'
'<div id="side_version">%s</div>'
'</a>'
- '</div>\n' % (_("Go to main overview"), html.attrencode(config.start_url), defaults.check_mk_version))
+ '</div>\n' % (_("Go to main overview"), html.attrencode(config.user.get("start_url") or config.start_url), defaults.check_mk_version))
def render_messages():
for msg in notify.get_gui_messages():
diff --git a/web/plugins/userdb/user_attributes.py b/web/plugins/userdb/user_attributes.py
index bc67d7d..ec5224d 100644
--- a/web/plugins/userdb/user_attributes.py
+++ b/web/plugins/userdb/user_attributes.py
@@ -64,4 +64,14 @@ declare_user_attribute(
domain = "check_mk",
)
+declare_user_attribute(
+ "start_url",
+ TextAscii(title = _("Start-URL to display in main frame"),
+ help = _("When you point your browser to the Multisite GUI, usually the dashboard "
+ "is shown in the main (right) frame. You can replace this with any other "
+ "URL you like here."),
+ size = 80,
+ default_value = "dashboard.py",
+ attrencode = True),
+ domain = "multisite")