Module: check_mk
Branch: master
Commit: 26e2bb51e03cd092156c21f11f72e9ca2e84a6c4
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=26e2bb51e03cd0…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Mon Sep 24 11:48:42 2018 +0200
6714 FIX docker_container_status: Fixed possible "ValueError" exception
Change-Id: Ic993ad9862b958d942aa597053f157219050ca14
---
.werks/6714 | 11 +++++++++++
checks/docker_container_status | 2 +-
2 files changed, 12 insertions(+), 1 deletion(-)
diff --git a/.werks/6714 b/.werks/6714
new file mode 100644
index 0000000..e163c68
--- /dev/null
+++ b/.werks/6714
@@ -0,0 +1,11 @@
+Title: docker_container_status: Fixed possible "ValueError" exception
+Level: 1
+Component: checks
+Class: fix
+Compatible: compat
+Edition: cre
+State: unknown
+Version: 1.6.0i1
+Date: 1537782461
+
+
diff --git a/checks/docker_container_status b/checks/docker_container_status
index 68604bb..fd9c8ce 100644
--- a/checks/docker_container_status
+++ b/checks/docker_container_status
@@ -35,7 +35,7 @@ def parse_docker_container_status(info):
# line. We assume that this a full JSON object. The rest of the section is skipped.
# When a container got piggyback data from multiple hosts (e.g. a cluster) this
results
# in multiple JSON objects handed over to this check.
- json_raw_data = info[0][0]
+ json_raw_data = " ".join(info[0])
import json
return json.loads(json_raw_data)