Jenkins: How to add a JDK version

This guide will show you how to add a JDK version to Jenkins. If you plan to run a Java build requiring a specific version of the Java Development Kit, you need to do this.

What is a JDK?

JDK is short for Java Development Kit, and it is a core technology packages used in Java programming. The JDK allows developers to create Java programs. Once compiled, the Java code can then be executed and run by the Java virtual machine and the Java runtime environment.

Let’s add a JDK version to Jenkins

You can add a JDK version by navigating to Jenkins -> Manage Jenkins -> Global Tool Configuration.

The global tool configuration menu will open the following window:

Next, click the JDK Installations” button under the JDK section to configure multiple JDK versions.

You should now see a window similar to this:

Next, follow these steps to add your JDK version:

  • Add a name for the Java version
  • Then check the toggle for Install automatically.
  • Next select the JDK Version from the dropdown.
  • Enter your Oracle account credentials.
  • Check the License Agreement checkbox.
  • Then finally click the “Save” button.

Finally, you can also use installers other than Oracle. So, if you need to change it, click the “Add Installer” select list for the available options.

Wrapping up

Now you know how to add a JDK version to your Jenkins installation.

You may also be interested in

About the Authors

Anto's editorial team loves the cloud as much as you! Each member of Anto's editorial team is a Cloud expert in their own right. Anto Online takes great pride in helping fellow Cloud enthusiasts. Let us know if you have an excellent idea for the next topic! Contact Anto Online if you want to contribute.

Support the Cause

Support Anto Online and buy us a coffee. Anything is possible with coffee and code.

Buy me a coffee

About Anto Online

Having started his career in 1999 as a Desktop Support Engineer, Anto soon changed paths and became a developer. After several years of development experience, he transitioned into a consultant. As an enterprise application consultant for a leading SaaS software provider, Anto specializes in AWS's serverless technologies. By day, Anto focuses on helping customers leverage the power of serverless technologies. By night, he indulges his passion for cloud computing by playing with Python and trying out things that are currently beyond the scope of his work. Sometimes Anto needs help as there are not enough hours at night. So Anto relies on a team of fellow Cloud enthusiasts to help him out. Each one is a Cloud expert in their own right, and Anto takes great pride in helping them learn and grow.

View all posts by Anto Online →

Leave a Reply

Your email address will not be published.