diff --git a/benchmark/Dockerfile b/benchmark/Dockerfile index c6bb8e853ed..0279186478a 100644 --- a/benchmark/Dockerfile +++ b/benchmark/Dockerfile @@ -1,14 +1,20 @@ # Petclinic download and compilation stage FROM eclipse-temurin:17-jammy as petclinic +ARG SPRING_PETCLINIC_COMMIT=cefaf55dd124d0635abfe857c3c99a3d3ea62017 + RUN apt-get update \ && apt-get -y install git \ && apt-get -y clean \ && rm -rf /var/lib/apt/lists/* -RUN git clone --depth 1 --branch main --single-branch https://github.com/spring-projects/spring-petclinic.git \ - && cd spring-petclinic \ - && ./mvnw dependency:go-offline +RUN set -eux;\ + git init spring-petclinic;\ + cd spring-petclinic;\ + git remote add origin https://github.com/spring-projects/spring-petclinic.git;\ + git fetch --depth 1 origin ${SPRING_PETCLINIC_COMMIT};\ + git checkout ${SPRING_PETCLINIC_COMMIT};\ + ./mvnw dependency:go-offline RUN cd spring-petclinic \ && ./mvnw package -Dmaven.test.skip=true \