-
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.
feat: Built a graalvm native image and separate x86, arm64 docker images
- Loading branch information
1 parent
b69d74d
commit e9b1a19
Showing
12 changed files
with
322 additions
and
39 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
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
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,4 +1,18 @@ | ||
FROM eclipse-temurin:17.0.9_9-jre-alpine | ||
COPY build/libs/kafka-lag-monitor-*-all.jar kafka-lag-monitor.jar | ||
FROM ghcr.io/graalvm/native-image-community:17-ol8 as graalvm | ||
|
||
COPY . /home/app/micronaut-graal-app | ||
WORKDIR /home/app/micronaut-graal-app | ||
|
||
RUN native-image -cp build/libs/*-all.jar | ||
|
||
|
||
|
||
FROM gcr.io/distroless/base-debian11:latest | ||
|
||
LABEL maintainer="devatherock@gmail.com" | ||
LABEL io.github.devatherock.version="1.0.0" | ||
|
||
EXPOSE 8080 | ||
CMD java -Dcom.sun.management.jmxremote -noverify ${JAVA_OPTS} -jar kafka-lag-monitor.jar | ||
|
||
COPY --from=graalvm /home/app/micronaut-graal-app/micronautgraalapp /micronaut-graal-app/micronautgraalapp | ||
ENTRYPOINT ["/micronaut-graal-app/micronautgraalapp"] |
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
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
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
Oops, something went wrong.