-
Notifications
You must be signed in to change notification settings - Fork 64
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
changes to detect jre version from build.gradle
- Loading branch information
1 parent
580337c
commit 9841f8d
Showing
6 changed files
with
100 additions
and
3 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
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 |
---|---|---|
@@ -0,0 +1,2 @@ | ||
Dockerfile | ||
charts/ |
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 |
---|---|---|
@@ -0,0 +1,17 @@ | ||
FROM gradle:{{BUILDERVERSION}} as BUILD | ||
|
||
COPY --chown=gradle:gradle . /project | ||
COPY gradlew gradlew | ||
COPY gradle/wrapper gradle/wrapper | ||
RUN chmod +x gradle/wrapper | ||
RUN chmod +x gradlew | ||
RUN ./gradlew -i -s -b /project/build.gradle clean build | ||
|
||
FROM eclipse-temurin:{{VERSION}} | ||
ENV PORT {{PORT}} | ||
EXPOSE {{PORT}} | ||
|
||
COPY --from=BUILD /project/build/libs/* /opt/ | ||
WORKDIR /opt/ | ||
RUN ls -l | ||
CMD ["/bin/bash", "-c", "find -type f -name '*SNAPSHOT.jar' | xargs java -jar"] |
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 |
---|---|---|
@@ -0,0 +1,22 @@ | ||
language: gradlew | ||
displayName: Gradlew | ||
nameOverrides: | ||
- path: "dockerignore" | ||
prefix: "." | ||
variables: | ||
- name: "PORT" | ||
description: "the port exposed in the application" | ||
type: int | ||
- name: "BUILDERVERSION" | ||
description: "the version of gradle used during the builder stage to generate the executable" | ||
exampleValues: ["jdk8","jdk11","jdk17","jdk19"] | ||
- name: "VERSION" | ||
description: "the version of openjdk used by the application" | ||
exampleValues: ["8-jre","11-jre","17-jre","19-jre"] | ||
variableDefaults: | ||
- name: "BUILDERVERSION" | ||
value: "jdk11" | ||
- name: "VERSION" | ||
value: "11-jre" | ||
- name: "PORT" | ||
value: "80" |