Installation on Linux Using the Zulu Docker Registry
Before you install Zulu, complete the steps described in the section Preparing the Zulu Installation Platform.
-
Log in to your system as
root
or usesudo
. -
Install Docker. See https://docs.docker.com/installation/.
-
Install the Docker runtime onto your Linux system.
Example:
sudo yum install docker
-
Start the Docker service in the background.
Example:
sudo service docker start
Alternatively, to have the Docker service start at boot time, use the
chkconfig docker
command.
-
-
Locate the Zulu Docker files from the Docker registry at: https://registry.hub.docker.com/u/azul/zulu-openjdk/.
-
Identify a Zulu version from the list of Docker tags. Click the Tags tab.
-
Run the Zulu Docker container. From your command line:
-
For Ubuntu
docker run -it --rm azul/zulu-openjdk:<zulu_docker_tag> java -version
For example, to use version 7 of JDK, run the following:
docker run -it --rm azul/zulu-openjdk:7 java -version
-
For Debian
docker run -it --rm azul/zulu-openjdk-debian:<zulu_docker_tag> java -version
For example, to use version 7 of JDK, run the following:
docker run -it --rm azul/zulu-openjdk-debian:7 java -version
-
For CentOS
docker run -it --rm azul/zulu-openjdk-centos:<zulu_docker_tag> java -version
The following example shows Docker checking for an existing Zulu image, then pulling the image from the repository.
docker run -it --rm azul/zulu-openjdk-centos:7 java -version
Response shows Docker checks for an existing Zulu image, then pulls the image from the repository.
Unable to find image 'azul/zulu-openjdk-centos:7' locally 7: Pulling from azul/zulu-openjdk-centos ab5ef0e58194: Pull complete b711fe66e784: Pull complete Digest: sha256:612957dc50cddef75301b55033366135fd376a7323de38774353a05d30fbea56 Status: Downloaded newer image for azul/zulu-openjdk-centos:7 openjdk version "1.7.0_262" OpenJDK Runtime Environment (Zulu 7.38.0.11-CA-linux64) (build 1.7.0_262-b10) OpenJDK 64-Bit Server VM (Zulu 7.38.0.11-CA-linux64) (build 24.262-b10, mixed mode)
-