Module: check_mk
Branch: master
Commit: 50b15c3e20b289d2beabd5279723897a37528b53
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=50b15c3e20b289…
Author: Konstantin Büttner <kb(a)mathias-kettner.de>
Date: Fri Apr 6 11:47:28 2018 +0200
docker_node_info inventory plugin: Include information about node labels
Change-Id: I868cc5a787d708305cc914f4a8f623b9e86021c1
---
inventory/docker_node_info | 3 +++
1 file changed, 3 insertions(+)
diff --git a/inventory/docker_node_info b/inventory/docker_node_info
index 718ca5c..2d8914e 100644
--- a/inventory/docker_node_info
+++ b/inventory/docker_node_info
@@ -30,6 +30,9 @@ def inv_docker_node_info(parsed, inventory_tree):
node = inventory_tree.get_dict("software.applications.docker.")
node["version"] = parsed[u"ServerVersion"]
+ node_labels =
inventory_tree.get_list("software.applications.docker.node_labels:")
+ node_labels += [ {"label": label} for label in parsed[u"Labels"]
]
+
inv_info['docker_node_info'] = {
'inv_function' : inv_docker_node_info,