Docker Community Forums

Share and learn in the Docker community.

Official Oracle Java Dockerfile


(Amithaprabath) #1

Hi,

Can anyone send me the official Oracle Java Dockerfile to me. I found it is difficult to download and install since the connection drops in the middle when the following part of the docker file is being implemented.

RUN cd /tmp &&
wget http://download.oracle.com/otn-pub/java/jdk/8u111-b14/jdk-8u111-linux-x64.tar.gz &&
tar xzvf jdk-8u111-linux-x64.tar.gz &&
rm -f jdk-8u111-linux-x64.tar.gz &&
mv -r jdk1.8.0_111/ /usr/local &&
echo ‘export JAVA_HOME=/usr/local/jdk1.8.0_111/’ >> ~/.bashrc &&
echo ‘export JRE_HOME=/usr/local/jdk1.8.0_111/jre’ >> ~/.bashrc &&
echo ‘export PATH=$PATH:$JAVA_HOME/bin:$JRE_HOME/bin’ >> ~/.bashrc &&
source ~/.bashrc


(Vp2405) #2

https://hub.docker.com/_/openjdk/