Skip to content

Commit

Permalink
更改jdk
Browse files Browse the repository at this point in the history
  • Loading branch information
ZhouYixun committed May 20, 2022
1 parent 740d59c commit 4b7debd
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/main/docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,12 @@ RUN apt-get -qqy update && \
libasound2-dev freeglut3-dev libgtk2.0-dev libusb-dev zlib1g libffi-dev libbz2-dev zlib1g-dev \
&& rm -rf /var/lib/apt/lists/*

RUN wget -O java.tar.gz https://download.oracle.com/java/17/latest/jdk-17_linux-x64_bin.tar.gz && \
RUN wget -O java.tar.gz https://github.com/AdoptOpenJDK/openjdk15-binaries/releases/download/jdk-15.0.2%2B7/OpenJDK15U-jdk_x64_linux_hotspot_15.0.2_7.tar.gz && \
tar zxvf java.tar.gz && rm java.tar.gz && \
chmod a+x -R /root/jdk-17.0.3.1 && \
chown -R root:root /root/jdk-17.0.3.1
chmod a+x -R /root/jdk-15.0.2+7 && \
chown -R root:root /root/jdk-15.0.2+7

ENV JAVA_HOME="/root/jdk-17.0.3.1" \
ENV JAVA_HOME="/root/jdk-15.0.2+7" \
PATH=$PATH:$JAVA_HOME/bin

ENV ANDROID_HOME=/root
Expand Down Expand Up @@ -86,4 +86,4 @@ ADD /plugins /root/plugins
ADD /src/main/docker/config /root/config
ADD /target/sonic-agent-linux-x86_64.jar /root
RUN ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
ENTRYPOINT ["/root/jdk-17.0.3.1/bin/java","-server","-Dfile.encoding=utf-8","-XX:-UseGCOverheadLimit","-XX:+DisableExplicitGC","-XX:SurvivorRatio=1","-XX:LargePageSizeInBytes=128M","-XX:SoftRefLRUPolicyMSPerMB=0","-Djava.security.egd=file:/dev/./urandom","--add-opens java.base/java.lang=ALL-UNNAMED","--add-opens java.base/java.util=ALL-UNNAMED","--add-opens java.base/java.math=ALL-UNNAMED","-jar","sonic-agent-linux-x86_64.jar"]
ENTRYPOINT ["/root/jdk-15.0.2+7/bin/java","-server","-Dfile.encoding=utf-8","-XX:-UseGCOverheadLimit","-XX:+DisableExplicitGC","-XX:SurvivorRatio=1","-XX:LargePageSizeInBytes=128M","-XX:SoftRefLRUPolicyMSPerMB=0","-Djava.security.egd=file:/dev/./urandom","--add-opens java.base/java.lang=ALL-UNNAMED","--add-opens java.base/java.util=ALL-UNNAMED","--add-opens java.base/java.math=ALL-UNNAMED","-jar","sonic-agent-linux-x86_64.jar"]

0 comments on commit 4b7debd

Please sign in to comment.