diff --git a/docker-bench-security.sh b/docker-bench-security.sh index 55fe677..0659d07 100755 --- a/docker-bench-security.sh +++ b/docker-bench-security.sh @@ -42,16 +42,6 @@ usage () { EOF } -yell "# ------------------------------------------------------------------------------ -# Docker Bench for Security v1.0.0 -# -# Docker, Inc. (c) 2015 -# -# Checks for dozens of common best-practices around deploying Docker containers in production. -# Inspired by the CIS Docker 1.6 Benchmark: -# https://benchmarks.cisecurity.org/tools2/docker/CIS_Docker_1.6_Benchmark_v1.0.0.pdf -# ------------------------------------------------------------------------------" - # Get the flags # If you add an option here, please # remember to update usage() above. @@ -64,6 +54,20 @@ do esac done +if [ -z "$logger" ]; then + logger="${myname}.log" +fi + +yell "# ------------------------------------------------------------------------------ +# Docker Bench for Security v1.0.0 +# +# Docker, Inc. (c) 2015 +# +# Checks for dozens of common best-practices around deploying Docker containers in production. +# Inspired by the CIS Docker 1.6 Benchmark: +# https://benchmarks.cisecurity.org/tools2/docker/CIS_Docker_1.6_Benchmark_v1.0.0.pdf +# ------------------------------------------------------------------------------" + # Warn if not root ID=$(id -u) if [ "x$ID" != "x0" ]; then @@ -71,10 +75,6 @@ if [ "x$ID" != "x0" ]; then sleep 3 fi -if [ -z "$logger" ]; then - logger="${myname}.log" -fi - logit "Initializing $(date)\n" # Load all the tests from tests/ and run them