Skip to content

Commit

Permalink
fix to update.sh
Browse files Browse the repository at this point in the history
Signed-off-by: Lachlan Roberts <[email protected]>
  • Loading branch information
lachlan-roberts committed Jun 21, 2022
1 parent 55272e7 commit d278d4d
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions update.sh
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,8 @@ fi
paths=( "${paths[@]%/}" )

REPOSITORY_URL="${REPOSITORY_URL:=https://repo1.maven.org/maven2/org/eclipse/jetty}"
JETTY_HOME_URL="$REPOSITORY_URL/jetty-home/$JETTY_VERSION/jetty-home-$JETTY_VERSION.tar.gz"
JETTY_HOME_URL="$REPOSITORY_URL/jetty-home/\$JETTY_VERSION/jetty-home-\$JETTY_VERSION.tar.gz"
JETTY_DISTRO_URL="$REPOSITORY_URL/jetty-distribution/\$JETTY_VERSION/jetty-distribution-\$JETTY_VERSION.tar.gz"
MAVEN_METADATA_URL="$REPOSITORY_URL/jetty-server/maven-metadata.xml"

available=( $( curl -sSL "$MAVEN_METADATA_URL" | grep -Eo '<(version)>[^<]*</\1>' | awk -F'[<>]' '{ print $3 }' | sort -Vr ) )
Expand Down Expand Up @@ -127,7 +128,7 @@ for path in "${paths[@]}"; do
sed -ri 's/^(ENV JETTY_VERSION) .*/\1 '"$fullVersion"'/; ' "$path/Dockerfile"

# Update repository URL.
sed -ri 's|^(ENV JETTY_TGZ_URL) .*|\1 '"$JETTY_HOME_URL"'|; ' "$path/Dockerfile"
sed -ri 's|^(ENV JETTY_TGZ_URL) .*|\1 '"$JETTY_DISTRO_URL"'|; ' "$path/Dockerfile"
fi
fi
done

0 comments on commit d278d4d

Please sign in to comment.