-
Notifications
You must be signed in to change notification settings - Fork 9
/
Dockerfile
24 lines (18 loc) · 779 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
FROM adoptopenjdk:15.0.2_7-jre-hotspot-focal
MAINTAINER René Reitmann <[email protected]>
VOLUME /tmp
# use unpacked spring boot jar to avoid file io
COPY target/app /app/
COPY run.sh run.sh
COPY jvmkill.so.sha512 jvmkill.so.sha512
# install all available package updates
RUN apt-get update && apt-get upgrade -y -q && apt-get dist-upgrade -y -q
# add kill agent for correct OutOfMemory Handling
RUN apt update \
&& apt install -y --no-install-recommends curl\
&& rm -rf /var/lib/apt/lists/*\
&& curl https://java-buildpack.cloudfoundry.org/jvmkill/bionic/x86_64/jvmkill-1.16.0_RELEASE.so --output /app/jvmkill.so\
&& echo "$(cut -d' ' -f1 /jvmkill.so.sha512) /app/jvmkill.so" | sha512sum --check\
&& apt remove curl -y\
&& apt autoremove -y
ENTRYPOINT ["/run.sh"]