Rechercher dans ce blog

lundi 23 avril 2012

4. Jenkins (1/2)

Now, that we have the source code repository. I would like to put in place a continuous integration environment. An environment that I like and which is pretty easy to use is Jenkins. It provides automatic build verification, junit tests, etc.

In this post, I will explain:


  1. How to install Jenkins
  2. How to configure Jenkins
  3. How to use Jenkins

If you already know how it works, forget this post and read the next one!

Jenkins installation

Normally, we should install a new OS, configure the OS, install the Jenkins dependencies, configure the Jenkins dependencies and so on, and so on... It would take ages to do it and it is absolutely not interesting. In order to go faster, we will install a virtual appliance and configure only the minimal...

A virtual appliance is a virtual machine (VM) already configured that we can boot in an hypervisor (in my case VMWare workstation). The first boot will configure a few things on the VM and we can use it afterward.

Download the Jenkins virtual appliance

The Jenkins virtual appliance can be downloaded here: http://susestudio.com/a/u1OC8F/jenkins. There are a few login steps to perform but eventually you should get the VM. In my case, it was called: Jenkins-i686-0.0.5.vmx.tar.gz.

  1. Download the virtual appliance
  2. Decompress the file, you should get a folder containing two files:
    • vmx: is the configuration of the VM.
    • vmdk: the VM's virtual disk
  3. Let's copy the folder in the VMWare "Virtual Machines" folder

Start Jenkins virtual appliance

Now that we have downloaded, decompressed and moved the folder at the correct location, let's start the virtual appliance for the first time...

  1. Start VMWare workstation
  2. Go in File->Open
  3. Select the vmx file in the folder
  4. Normally, you should have a new VM in your VMs list.
  5. Let's start the virtual appliance.

Configure the virtual appliance

The first boot is very important in virtual appliances as it will configure the virtual machine and if things go wrong, it may be pretty complex to reset some settings. 

  1. The first time you start, you should be asked to upgrade the virtual machine: Select "Upgrade". Usually, you do not have to bother about this option as it may be useful only if you plan to downgrade to an older VMWare version which is rarely the case.
  2. When starting, you should get the following screen:
  3. If you did not press any key, the configuration should start. If it does not, press <enter>
  4. After a couple of seconds, you should get the Timezone configuration panel. Select your timezone and select "Next". Please note that the mouse should not work and you will have to play with the tab button to select the proper timezone...
  5. After a couple of more seconds, you should get the following screen. Congratulations, your VM is up and running.
Now that the virtual appliance is running, you should be able to configure the virtual machine using your browser which will be easier...


  1. On the VM, you should see a green line. Go  on this URL with your browser... The username is "root" and password "ch@ngeme"
  2. You should get an error message related to Java, do not bother about it for the moment... Configure the password, the users, etc.
  3. Now, let's go to the "Software Repositories" panel and disable webyast and java. It seems that there was a bug in webyast and upgrading it was causing it to crash.... 
  4. It will take a very long time...
  5. After a while, everything should be installed, reboot the VM now.
This concludes the install of the Jenkins virtual appliance. In next post, we will see how to configure Jenkins.

Aucun commentaire:

Enregistrer un commentaire