mirror of
https://github.com/docker/docker-bench-security.git
synced 2024-11-01 00:21:45 +01:00
move HAVE_JQ into req_programs
This commit is contained in:
parent
79407ce361
commit
523556b4ac
1 changed files with 5 additions and 6 deletions
|
@ -11,6 +11,11 @@ req_programs() {
|
|||
for p in $1; do
|
||||
command -v "$p" >/dev/null 2>&1 || { printf "Required program not found: %s\n" "$p"; exit 1; }
|
||||
done
|
||||
if command -v jq >/dev/null 2>&1; then
|
||||
HAVE_JQ=true
|
||||
else
|
||||
HAVE_JQ=false
|
||||
fi
|
||||
if command -v ss >/dev/null 2>&1; then
|
||||
netbin=ss
|
||||
return
|
||||
|
@ -112,12 +117,6 @@ get_docker_configuration_file() {
|
|||
CONFIG_FILE='/dev/null'
|
||||
}
|
||||
|
||||
if command -v jq &> /dev/null; then
|
||||
HAVE_JQ=true
|
||||
else
|
||||
HAVE_JQ=false
|
||||
fi
|
||||
|
||||
get_docker_configuration_file_args() {
|
||||
OPTION="$1"
|
||||
|
||||
|
|
Loading…
Reference in a new issue