Skip to content
This repository has been archived by the owner on Jan 22, 2022. It is now read-only.

Commit

Permalink
Force picking altest tomcat version
Browse files Browse the repository at this point in the history
  • Loading branch information
dotcmsbuild committed Feb 10, 2021
1 parent 15157b9 commit d5ffdcf
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions images/dotcms/build-src/build_dotcms.sh
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ build_by_commit() {
}

set_tomcat_dir() {
tomcat_versions=$(find /srv/dotserver/ -type d -name tomcat-* | grep -oP "(?<=tomcat-)[0-9]{1}\.[0-9]{1}\.[0-9]+$")
tomcat_versions=$(find /srv/dotserver/ -type d -name tomcat-* | grep -oP "(?<=tomcat-)[0-9]{1}\.[0-9]{1}\.[0-9]+$ | sort -k1.2n")
echo "Found tomcat installations:
${tomcat_versions}"

Expand All @@ -50,7 +50,7 @@ set_tomcat_dir() {
exit 1
fi
else
tomcat_version=$(find /srv/dotserver/ -type d -name tomcat-* | grep -oP "(?<=tomcat-)[0-9]{1}\.[0-9]{1}\.[0-9]+$" | tail -n 1)
tomcat_version=$(find /srv/dotserver/ -type d -name tomcat-* | grep -oP "(?<=tomcat-)[0-9]{1}\.[0-9]{1}\.[0-9]+$" | sort -k1.2n | tail -n 1)
[[ -z "${tomcat_version}" ]] && echo "ERROR: Unable to determine Tomcat version" && exit 1
fi

Expand Down

0 comments on commit d5ffdcf

Please sign in to comment.