Module: check_mk
Branch: master
Commit: 4b227e42b108cb675a5b54eddaacd437389095ae
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=4b227e42b108cb…
Author: Goetz Golla <gg(a)mathias-kettner.de>
Date: Tue Sep 2 15:06:51 2014 +0200
Better title for werk
---
.werks/651 | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/.werks/651 b/.werks/651
index 7325efb..066ba9c 100644
--- a/.werks/651
+++ b/.werks/651
@@ -1,4 +1,4 @@
-Title: f5_bigip_interfaces: indentation error and oid to determine the interface state fixed
+Title: f5_bigip_interfaces: Fix invalid throughput values, detect newer F5 devices
Level: 1
Component: checks
Compatible: compat
@@ -6,10 +6,9 @@ Version: 1.2.5i6
Date: 1409238534
Class: fix
-A major indentation errors has lead to interface throuputs identical for all ifs.
-The oid for the determination of the if state was wrong
+A major indentation error has lead to interface throuputs identical for all IFs.
+The oid for the determination of the if state was wrong.
Both errors have been fixed.
-
Also the scan function was extended to detect more and newer f5 devices
Module: check_mk
Branch: master
Commit: 98af2b55026c6a7820bf22dc558bd45c16ede86e
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=98af2b55026c6a…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Tue Sep 2 14:57:48 2014 +0200
Better help text for clustered_services_mapping
---
web/plugins/wato/check_mk_configuration.py | 12 ++++++++----
1 file changed, 8 insertions(+), 4 deletions(-)
diff --git a/web/plugins/wato/check_mk_configuration.py b/web/plugins/wato/check_mk_configuration.py
index 6f19786..716a1cb 100644
--- a/web/plugins/wato/check_mk_configuration.py
+++ b/web/plugins/wato/check_mk_configuration.py
@@ -2039,10 +2039,14 @@ group = "monconf/" + _("Various")
register_rule(group,
"clustered_services_mapping",
TextAscii(
- title = _("Explicit mapping of Clustered Services"),
- help = _( "It's possible to have overlaping nodes between multiple clusters."
- "With this rule the direct mapping of services from nodes to the "
- "favored Cluster can be done."),
+ title = _("Clustered services for overlapping clusters"),
+ label = _("Assign services to the following cluster:"),
+ help = _("It's possible to have clusters that share nodes. You could say that "
+ "such clusters "overlap". In such a case using the ruleset "
+ "<i>Clustered services</i> is not sufficient since it would not be clear "
+ "to which of the several possible clusters a service found on such a shared "
+ "node should be assigned to. With this ruleset you can assign services and "
+ "explicitely specify which cluster assign them to."),
),
itemtype = "service",
)
Module: check_mk
Branch: master
Commit: 0c346794205b3f5fbec313e55935aa325763bf6e
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=0c346794205b3f…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Tue Sep 2 12:58:38 2014 +0200
#1392 WATO Folder filter: show only the paths a user is allowed to see
---
.werks/1392 | 9 +++++++++
ChangeLog | 1 +
web/plugins/views/wato.py | 19 ++++++++++++++++++-
3 files changed, 28 insertions(+), 1 deletion(-)
diff --git a/.werks/1392 b/.werks/1392
new file mode 100644
index 0000000..54eca8f
--- /dev/null
+++ b/.werks/1392
@@ -0,0 +1,9 @@
+Title: WATO Folder filter: show only the paths a user is allowed to see
+Level: 1
+Component: multisite
+Compatible: compat
+Version: 1.2.5i6
+Date: 1409655497
+Class: feature
+
+
diff --git a/ChangeLog b/ChangeLog
index cf3a8c9..5220e10 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -73,6 +73,7 @@
Multisite:
* 1066 Implemented Dashboard Designer...
+ * 1392 WATO Folder filter: show only the paths a user is allowed to see
* 1067 FIX: Fixed login problem in LDAP connector when no user filter specified...
* 1094 FIX: sidebar snaping 'Tree of folders': fixed exception
* 1154 FIX: Availability: Fixed unwanted redirect to edit annotation page after editing availability options...
diff --git a/web/plugins/views/wato.py b/web/plugins/views/wato.py
index 023f51f..bcc414d 100644
--- a/web/plugins/views/wato.py
+++ b/web/plugins/views/wato.py
@@ -47,7 +47,24 @@ class FilterWatoFile(Filter):
def display(self):
self.check_wato_data_update()
- html.select(self.name, [("", "")] + self.selection)
+ # Note: WATO Folders that the user has not permissions to must not be visible.
+ # Permissions in this case means, that the user has view permissions for at
+ # least one host in that folder.
+ result = html.live.query("GET hosts\nCache: reload\nColumns: filename\nStats: state >= 0\n")
+ allowed_folders = set([""])
+ for path, host_count in result:
+ # convert '/wato/server/hosts.mk' to 'server'
+ folder = path[6:-9]
+ # allow the folder an all of its parents
+ parts = folder.split("/")
+ subfolder = ""
+ for part in parts:
+ if subfolder:
+ subfolder += "/"
+ subfolder += part
+ allowed_folders.add(subfolder)
+
+ html.select(self.name, [("", "")] + [ entry for entry in self.selection if (entry[0] in allowed_folders) ])
def filter(self, infoname):
self.check_wato_data_update()
Module: check_mk
Branch: master
Commit: 7c75931eeac50982a651c23214583c45ebca1d4d
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=7c75931eeac509…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Tue Sep 2 12:21:43 2014 +0200
Visuals: fix two bugs in edit mode for views
---
web/htdocs/views.py | 13 +++++++++----
1 file changed, 9 insertions(+), 4 deletions(-)
diff --git a/web/htdocs/views.py b/web/htdocs/views.py
index 0d4a3a0..d6ba10d 100644
--- a/web/htdocs/views.py
+++ b/web/htdocs/views.py
@@ -622,7 +622,7 @@ def render_view_config(view):
for ident, vs in view_editor_specs(view['context_type'], ds_name):
ty = visuals.context_types[view['context_type']]
if ident == 'filters' and type(ty['parameters']) == list:
- value = view[ident]
+ value = view.get(ident, []) # "filters" might be missing, for single-context views
else:
value = view
vs.render_input(ident, value)
@@ -1393,13 +1393,16 @@ def get_limit():
return config.soft_query_limit
def view_title(view):
- extra_titles = [ ]
+ extra_titles = []
datasource = multisite_datasources[view["datasource"]]
tablename = datasource["table"]
context_type = visuals.context_types[view['context_type']]
if context_type['single']:
- extra_titles = [ v for k, v in visuals.get_context_html_vars(view) ]
+ # Beware: if a single context view is being visited *without* a context, then
+ # the value of the context variable(s) is None. In order to avoid exceptions,
+ # we simply drop these here.
+ extra_titles = [ v for k, v in visuals.get_context_html_vars(view) if v != None ]
else:
used_filters = [ multisite_filters[fn] for fn in view["context"].keys() ]
for filt in used_filters:
@@ -1407,7 +1410,9 @@ def view_title(view):
if heading:
extra_titles.append(heading)
- title = _u(view["title"]) + " " + ", ".join(extra_titles)
+ title = _u(view["title"])
+ if extra_titles:
+ title += " " + ", ".join(extra_titles)
for fn in ubiquitary_filters:
# Disable 'wato_folder' filter, if WATO is disabled or there is a single host view
Module: check_mk
Branch: master
Commit: 081ca5531b8e91fb1ecac526c528709e80d864d7
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=081ca5531b8e91…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Tue Sep 2 12:21:20 2014 +0200
Updated bug entries #2160, #2161
---
.bugs/2160 | 10 ++++++++++
.bugs/2161 | 11 +++++++++++
2 files changed, 21 insertions(+)
diff --git a/.bugs/2160 b/.bugs/2160
new file mode 100644
index 0000000..9ab473d
--- /dev/null
+++ b/.bugs/2160
@@ -0,0 +1,10 @@
+Title: Visuals: when single-context views are shown without context, show proper error
+Component: multisite
+State: open
+Date: 2014-09-02 12:18:00
+Targetversion: future
+Class: bug
+
+In the table of all views, a single-context view should either not be clickable
+(except it has its context hard coded). Also we should display a useful error
+if the view is being called directly via URL.
diff --git a/.bugs/2161 b/.bugs/2161
new file mode 100644
index 0000000..47e1fd1
--- /dev/null
+++ b/.bugs/2161
@@ -0,0 +1,11 @@
+Title: Visual: single-context views with hardcoded context should not display filter
+Component: multisite
+State: open
+Date: 2014-09-02 12:20:34
+Targetversion: future
+Class: bug
+
+Currently the filter is being displayed, with an Warning icon, and any changes are silently
+ignored.
+
+The filter should not be visible in that case.