diff --git a/compose.yml b/compose.yml index 37ec692..cb1c10f 100644 --- a/compose.yml +++ b/compose.yml @@ -66,7 +66,7 @@ services: build: context: sample-back args: - - -Dspring.profiles.active=sample + jarargs: -Dspring.profiles.active=sample container_name: samplefam-api restart: always depends_on: diff --git a/sample-back/Dockerfile b/sample-back/Dockerfile index 40aa1e9..1389c1a 100644 --- a/sample-back/Dockerfile +++ b/sample-back/Dockerfile @@ -3,5 +3,8 @@ FROM openjdk:24-jdk-slim ARG JAR_FILE=target/*.jar COPY ${JAR_FILE} app.jar +ARG jarargs='' +ENV myArgs=$jarargs + EXPOSE 8080 -ENTRYPOINT ["java","-jar","/app.jar"] \ No newline at end of file +ENTRYPOINT java $myArgs -jar /app.jar \ No newline at end of file diff --git a/tds-back/Dockerfile b/tds-back/Dockerfile index 40aa1e9..1389c1a 100644 --- a/tds-back/Dockerfile +++ b/tds-back/Dockerfile @@ -3,5 +3,8 @@ FROM openjdk:24-jdk-slim ARG JAR_FILE=target/*.jar COPY ${JAR_FILE} app.jar +ARG jarargs='' +ENV myArgs=$jarargs + EXPOSE 8080 -ENTRYPOINT ["java","-jar","/app.jar"] \ No newline at end of file +ENTRYPOINT java $myArgs -jar /app.jar \ No newline at end of file