Skip to content

Commit

Permalink
Add JAVA_OPTS in docker image
Browse files Browse the repository at this point in the history
  • Loading branch information
aurambaj committed Jul 31, 2020
1 parent 3748386 commit 2de379c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
1 change: 1 addition & 0 deletions docker/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ services:
- "8080:8080"
restart: always
environment:
# JAVA_OPTS: '-Xms2g'
SPRING_APPLICATION_JSON: '{
"spring.flyway.enabled": "true",
"l10n.flyway.clean" : "false",
Expand Down
5 changes: 2 additions & 3 deletions webapp/src/main/docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,5 @@ FROM openjdk:8-alpine
VOLUME /tmp
ADD mojito-webapp-*-exec.jar app.jar
RUN sh -c 'touch /app.jar'
ENTRYPOINT ["java","-Djava.security.egd=file:/dev/./urandom","-jar","/app.jar"]


# starting with "exec doesn't seem to be needed with openjdk:8-alpine. As per docker documentation, it is required in general
ENTRYPOINT exec java $JAVA_OPTS -Djava.security.egd=file:/dev/./urandom -jar /app.jar

0 comments on commit 2de379c

Please sign in to comment.