-
Notifications
You must be signed in to change notification settings - Fork 131
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Issue #13970: Update CI to have Maven Version 3.9.5
- Loading branch information
Showing
2 changed files
with
23 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
37 changes: 22 additions & 15 deletions
37
devops/docker/no-exception-build-image/jdk-11-groovy-git-mvn/Dockerfile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,22 @@ | ||
##################### Using official groovy image ###################### | ||
FROM groovy:jdk11 | ||
##################### End of images used ############################### | ||
|
||
## Changing user to root to get access to /var/lib/dpkg/lock-frontend ## | ||
USER root | ||
##################### End of Change User ############################### | ||
|
||
##################### Installing Maven and git ######################### | ||
RUN apt-get update \ | ||
&& echo "Installing maven and git dependencies" \ | ||
&& apt-get install --yes --no-install-recommends \ | ||
git \ | ||
maven | ||
##################### End of install and Dockerfile #################### | ||
FROM cimg/base:2023.10 | ||
|
||
# ca-certificates-java must be installed AND configured before java + groovy installation | ||
RUN sudo apt update && \ | ||
sudo apt install ca-certificates-java && \ | ||
sudo apt install openjdk-11-jdk groovy jq -y | ||
|
||
ENV JAVA_HOME=/usr/lib/jvm/java-11-openjdk-amd64 \ | ||
GROOVY_HOME=/usr/share/groovy \ | ||
PATH=$GROOVY_HOME/bin:$PATH | ||
|
||
ENV MAVEN_VERSION=3.9.5 \ | ||
PATH=/opt/apache-maven/bin:$PATH | ||
|
||
RUN MAVEN_3_URL=https://www.apache.org/dist/maven/maven-3 && \ | ||
MAVEN_VERSION_URL=$MAVEN_VERSION/binaries/apache-maven-${MAVEN_VERSION}-bin.tar.gz && \ | ||
export URL=${MAVEN_3_URL}/${MAVEN_VERSION_URL} && \ | ||
curl -sSL --fail --retry 3 $URL -o apache-maven.tar.gz && \ | ||
sudo tar -xzf apache-maven.tar.gz -C /opt/ && \ | ||
rm apache-maven.tar.gz && \ | ||
sudo ln -s /opt/apache-maven-* /opt/apache-maven && \ | ||
mvn --version |