accept only if ADD in / #362

Signed-off-by: Thomas Sjögren <konstruktoid@users.noreply.github.com>
This commit is contained in:
Thomas Sjögren 2019-03-19 14:54:38 +01:00
parent 5370aef248
commit 740439d352

View file

@ -224,8 +224,8 @@ check_4_9() {
fail=0
add_images=""
for img in $images; do
if docker history --format "{{ .CreatedBy }}" --no-trunc "$img" | sed '$d' |\
grep -q 'ADD'; then
if docker history --format "{{ .CreatedBy }}" --no-trunc "$img" | \
sed '$d' | grep -q 'ADD.*in /\s$'; then
if [ $fail -eq 0 ]; then
fail=1
info "$check_4_9"