Setting up Continuous Integration on Jenkins 2

Installing Jenkins 2


Install JDK 8 on your machine.

Go to the official site

Download the jenkins.war

With Docker

Launch the Docker image (the default port has been changed to 18080):

docker container run -d --name jenkins2 -p 18080:8080 -p 50000:50000 jenkinsci/jenkins

Create a new Job

  • Add New Item
    • Enter an item name
    • Select pipeline
    • Click OK

Jenkins2 item

  • Definition: Pipeline script from SCM
  • SCM: Git
  • Repositories
    • Repository URL: select your repository here

Jenkins2 pipeline


Jenkins2 result