Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
Administrator committed Dec 10, 2024
1 parent 3bcd015 commit df6db66
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 6 deletions.
10 changes: 4 additions & 6 deletions backend/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
FROM openjdk:11-jre-slim
ENV HOME=/app
RUN mkdir -p $HOME
WORKDIR $HOME
CMD [ "chmod", "+x", "./gradlew" ]
EXPOSE 8081

ENTRYPOINT [ "./gradlew", "bootRun", "--continuous", "--args=--server.port=8081" ]
ARG JAR_FILE
COPY ${JAR_FILE} app.jar
EXPOSE 8081
ENTRYPOINT ["java","-jar","/app.jar"]
10 changes: 10 additions & 0 deletions backend/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -43,3 +43,13 @@ dependencies {
tasks.withType<Test> {
useJUnitPlatform()
}

plugins {
id 'com.palantir.docker' version '0.25.0' // Or the latest version
}

docker {
name "${project.name}:${project.version}"
files bootJar.archiveFile
buildArgs(['JAR_FILE': "${bootJar.archiveFileName.get()}"])
}

0 comments on commit df6db66

Please sign in to comment.