From 8fe0b5ea02731274bb9bb73879d9a4477edfd8d4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20Sj=C3=B6gren?= Date: Wed, 17 Jan 2018 16:11:04 +0100 Subject: [PATCH 1/2] add example community check MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Thomas Sjögren --- tests/99_community_checks.sh | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 tests/99_community_checks.sh diff --git a/tests/99_community_checks.sh b/tests/99_community_checks.sh new file mode 100644 index 0000000..a800b09 --- /dev/null +++ b/tests/99_community_checks.sh @@ -0,0 +1,18 @@ +#!/bin/sh +check_c() { + logit "\n" + info "99 - Community contributed checks" +} + +# check_c_1 +check_c_1() { + check_c_1="C.1 - This is a example check" + totalChecks=$((totalChecks + 1)) + if docker info --format='{{ .Architecture }}' | grep 'x86_64'; then + pass "$check_c_1" + logjson "c.1" "PASS" + else + warn "$check_c_1" + logjson "c.1" "WARN" + fi +} From 700202ac7b9df1af3c82d471fc9ef824b0e4a2d7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20Sj=C3=B6gren?= Date: Wed, 17 Jan 2018 16:13:29 +0100 Subject: [PATCH 2/2] add header MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Thomas Sjögren --- functions_lib.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/functions_lib.sh b/functions_lib.sh index 7d7d0e6..6afba6b 100644 --- a/functions_lib.sh +++ b/functions_lib.sh @@ -134,8 +134,8 @@ docker_swarm_configuration() { } community_checks() { - # check_c_1 - true; + check_c + check_c_1 } # CIS