-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: failed unit tests when compile with Container
because we didn't include `/usr/bin/git` inside container
- Loading branch information
minh
committed
Jun 27, 2024
1 parent
1090628
commit c69e179
Showing
1 changed file
with
11 additions
and
10 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,17 @@ | ||
FROM quay.io/quarkus/ubi-quarkus-mandrel-builder-image:23.1-jdk-21 | ||
|
||
USER root | ||
|
||
FROM docker.io/maven:3.9.7-eclipse-temurin-21-alpine AS build | ||
COPY pom.xml /app/gis/ | ||
COPY .mvn /app/gis/.mvn | ||
COPY mvnw /app/gis/ | ||
WORKDIR /app/gis | ||
RUN ./mvnw -q verify clean --fail-never | ||
|
||
RUN mvn -q verify clean --fail-never | ||
COPY . /app/gis | ||
RUN ./mvnw -B -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn clean package | ||
RUN native-image -march=compatibility -cp target/gis-*.jar "org.nqm.Gis" --no-fallback | ||
RUN apk add --no-cache git | ||
RUN mvn -B -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn clean package | ||
|
||
FROM quay.io/quarkus/ubi-quarkus-mandrel-builder-image:23.1-jdk-21 | ||
USER root | ||
WORKDIR /app/gis | ||
COPY --from=build /app/gis/target/gis-*.jar target/ | ||
COPY --from=build /app/gis/target/lib target/lib | ||
RUN native-image -march=compatibility -cp target/gis-*.jar "org.nqm.Gis" --no-fallback | ||
RUN mv org.nqm.gis gis | ||
RUN chmod +x gis | ||
RUN ./gis --version |