File tree Expand file tree Collapse file tree 1 file changed +4
-0
lines changed Expand file tree Collapse file tree 1 file changed +4
-0
lines changed Original file line number Diff line number Diff line change 20
20
echo " Testing $IMG base layer"
21
21
22
22
if [ -z " ${BUILDER} " ] || [ " ${BUILDER} " = ' docker' ] ; then
23
+ if [ -z " $( docker image ls -q gcr.io/distroless/static:latest) " ]; then
24
+ docker pull gcr.io/distroless/static:latest
25
+ fi
23
26
distroless_base=$( docker inspect --format=' {{index .RootFS.Layers 0}}' " gcr.io/distroless/static" ) || die " failed to inspect gcr.io/distroless/static"
24
27
img_base=$( docker inspect --format=' {{index .RootFS.Layers 0}}' " $IMG " ) || die " failed to inspect $IMG "
25
28
elif [ " ${BUILDER} " = ' buildah' ] ; then
29
+ buildah images -q gcr.io/distroless/static:latest 2> /dev/null || buildah pull gcr.io/distroless/static:latest
26
30
distroless_base=$( buildah inspect --type image --format=' {{index .OCIv1.RootFS.DiffIDs 0}}' " gcr.io/distroless/static" ) || die " failed to inspect gcr.io/distroless/static"
27
31
img_base=$( buildah inspect --type image --format=' {{index .OCIv1.RootFS.DiffIDs 0}}' " $IMG " ) || die " failed to inspect $IMG "
28
32
else
You can’t perform that action at this time.
0 commit comments