Skip to content
Permalink
Browse files

ISSUE-1360: change to looking for lower-case reponse from dockerhub w…

…hen tag isnt present.

The response for an image tag that has not been found is inside a JSON elemnt of "message" not the stated "details", it has also been lower-cased.

Signed-off-by: Alistair Hey <alistair.hey@gmail.com>
  • Loading branch information
Waterdrips authored and alexellis committed Oct 21, 2019
1 parent 672b7c4 commit 9855e2f92cbdf4dd7d223ff4605bb90f204f2579
Showing with 3 additions and 3 deletions.
  1. +3 −3 contrib/publish-arm.sh
@@ -48,13 +48,13 @@ do

for IMAGE in "${images[@]}"
do
TAG_PRESENT=$(curl -s "https://hub.docker.com/v2/repositories/${IMAGE}/tags/${TAG}-${ARM_VERSION}/" | grep -Po '"detail": *"[^"]*"' | grep -o 'Not found')
if [ "$TAG_PRESENT" = "Not found" ]; then
TAG_PRESENT=$(curl -s "https://hub.docker.com/v2/repositories/${IMAGE}/tags/${TAG}-${ARM_VERSION}/" | grep -Po '"message": *"[^"]*"' | grep -io 'not found')
if [ "$TAG_PRESENT" = "not found" ]; then
break
fi
done

if [ "$TAG_PRESENT" = "Not found" ]; then
if [ "$TAG_PRESENT" = "not found" ]; then
make ci-${ARM_VERSION}-build ci-${ARM_VERSION}-push
else
for IMAGE in "${images[@]}"

0 comments on commit 9855e2f

Please sign in to comment.
You can’t perform that action at this time.