Jenkins seems to be the top code build, integration and QA automation tool to support continuous delivery.
Jenkins allows me to kick of jobs on a schedule or ofter certain events and Jenkins will keep track of the status of the jobs and the results.
To get Jenkins installed, I read wiki.jenkins-ci.org and then read biouno.org to try my first Jenkins example.
I installed Jenkins on one of the VMs from the “landshark” demo environment for Delphix Express. Landshark consists of two Linux Centos VMs that provide source and target examples for Delphix Express. I used the “target” VM but could have just as easily used the “source” machine.
Installing Jenkins
To install Jenkins I did:
sudo wget -O /etc/yum.repos.d/jenkins.repo http://pkg.jenkins-ci.org/redhat/jenkins.repo
sudo rpm --import https://jenkins-ci.org/redhat/jenkins-ci.org.key
sudo yum install jenkins
Then
service jenkins start
This gives the message “OK” but actually Jenkins dies. The workaround was to edit /etc/sysconfig/jenkins and change
JENKINS_AJP_PORT="8009"
to
JENKINS_AJP_PORT="8010"
also starting jenkins by hand worked even without workaround
cd /usr/lib/jenkins
java -jar jenkins.war
I then accessed the Jenkins console at http://my_linux_vm:8080
Running Jenkins
Click on “create new jobs”
Name the job
Select “Freestyle project”
Schedule the “date” command to be run and every 5 minutes by doing:
Fill in “Build Triggers” by checking “Build periodically” and type in “H/5 * * * *”
Under build choose “Execute Shell” and type in “echo `date`”
After hitting “Save”, then letting 5 minutes pass you’ll see a new entry in “Build History” in the bottom left. Click on the “#1″.
Then click “Console Output”
and you will see the output of the shell script we scheduled to be run every 5 minutes.
Comments