Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/CISOfy/lynis.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Boelen <michael.boelen@cisofy.com>2019-07-16 14:20:30 +0300
committerMichael Boelen <michael.boelen@cisofy.com>2019-07-16 14:20:30 +0300
commitfa8bad20db100d95cf089b0b2d897c339327215c (patch)
tree2f80f2e015d26056cd741137dc4fdd069a6c4c5d /include/helper_audit_dockerfile
parent2777caf6d218aeb40c2ebd8af2564be8201eeff1 (diff)
Use -n instead of ! -z
Diffstat (limited to 'include/helper_audit_dockerfile')
-rw-r--r--include/helper_audit_dockerfile10
1 files changed, 5 insertions, 5 deletions
diff --git a/include/helper_audit_dockerfile b/include/helper_audit_dockerfile
index 3d18556f..b3eff024 100644
--- a/include/helper_audit_dockerfile
+++ b/include/helper_audit_dockerfile
@@ -59,11 +59,11 @@ fi
IS_ALPINE=$(echo ${IMAGE} | grep -i alpine)
IS_LATEST=$(echo ${TAG} | grep -i latest)
- if [ ! -z "${IS_DEBIAN}" ]; then IMAGE="debian"; fi
- if [ ! -z "${IS_FEDORA}" ]; then IMAGE="fedora"; fi
- if [ ! -z "${IS_UBUNTU}" ]; then IMAGE="ubuntu"; fi
- if [ ! -z "${IS_ALPINE}" ]; then IMAGE="alpine"; fi
- if [ ! -z "${IS_LATEST}" ]; then
+ if [ -n "${IS_DEBIAN}" ]; then IMAGE="debian"; fi
+ if [ -n "${IS_FEDORA}" ]; then IMAGE="fedora"; fi
+ if [ -n "${IS_UBUNTU}" ]; then IMAGE="ubuntu"; fi
+ if [ -n "${IS_ALPINE}" ]; then IMAGE="alpine"; fi
+ if [ -n "${IS_LATEST}" ]; then
ReportWarning "dockerfile" "latest TAG used. Specifying a targeted OS image and version is better for reproducible results."
fi