snuyanzin commented on code in PR #7:
URL: https://github.com/apache/flink-ci-docker/pull/7#discussion_r4054651179


##########
base/Dockerfile:
##########
@@ -95,14 +96,30 @@ ARG MAVEN_VERSION=3.8.6
 ARG USER_HOME_DIR="/root"
 ARG 
BASE_URL=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/${MAVEN_VERSION}
 
-RUN mkdir -p /usr/share/maven /usr/share/maven/ref \
+RUN mkdir -p /usr/share/maven \
   && curl -fsSL -o /tmp/apache-maven.tar.gz 
${BASE_URL}/apache-maven-${MAVEN_VERSION}-bin.tar.gz \
   && tar -xzf /tmp/apache-maven.tar.gz -C /usr/share/maven 
--strip-components=1 \
   && rm -f /tmp/apache-maven.tar.gz \
   && ln -s /usr/share/maven/bin/mvn /usr/bin/mvn
 
 ENV MAVEN_HOME /usr/share/maven
 
+# Download the Maven Wrapper once, then use it to stage its jar and pre-warm 
the
+# Maven distribution cache, so CI's ./mvnw needs no network to bootstrap.
+ARG MAVEN_WARM_VERSIONS="3.8.6 3.9.16"
+ARG MAVEN_WRAPPER_VERSION=3.3.4

Review Comment:
   download it once to avoid network issues during  build



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to