mirror of
https://github.com/docker/docker-bench-security.git
synced 2025-01-19 00:32:34 +01:00
null if no config file
Signed-off-by: Thomas Sjögren <konstruktoid@users.noreply.github.com>
This commit is contained in:
parent
1f499387c6
commit
ff314754a3
1 changed files with 3 additions and 5 deletions
|
@ -87,12 +87,10 @@ get_docker_configuration_file_args() {
|
|||
|
||||
if [ -f "$FILE" ]; then
|
||||
CONFIG_FILE="$FILE"
|
||||
elif [ -f '/etc/docker/daemon.json' ]; then
|
||||
CONFIG_FILE='/etc/docker/daemon.json'
|
||||
else
|
||||
CONFIG_FILE="/etc/docker/daemon.json"
|
||||
fi
|
||||
|
||||
if ! grep "$OPTION" "$CONFIG_FILE"; then
|
||||
echo 0
|
||||
CONFIG_FILE='/dev/null'
|
||||
fi
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue