Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3

Background:

"Continuous Integration (CI) is a software development practice where members of a team integrate their work frequently, usually each person integrates at least daily - leading to multiple integrations per day. Each integration is verified by an automated build (including test) to detect integration errors as quickly as possible. Many teams find that this approach leads to significantly reduced integration problems and allows a team to develop cohesive software more rapidly." (Martin Fowler, http://martinfowler.com/articles/continuousIntegration.html )

...

sipXecs use a distribute CI architecture where both master and slaves are configured as Amazon EC2 instances. Master role is to invoke builds on slave machines (configured as new instances at build time in case of nightly builds or as predefined slave containing Hudson agent and launched via execution of SSH command on master: Manage Hudson > Manage Nodes > ci-slave1.sipfoundry.org). No build is performed on master instance.

Security

sipXecs CI server is integrated with Crowd  (meaning that you can use same JIRA or wiki account to login in its console ). At this moment only the following groups (besides administrators with full control) are granted with access (list is open and will be modified based on community feedback): sipXecs-commiters and sipXecs-developers can start new builds and see current jobs status.

Notifications

sipXecs CI make use of email (on build success and failure, before starting a new build) and IRC (channel #sipx) notifications.

Type of builds

At the moment there are two type of builds performed by sipXecs CI server:

...

Plugin name

Version

Description

Hudson Cobertura Plugin

1.0

Used for integrating Cobertura coverage reports in sipXecs CI email notifications

Crowd integration

1.1

Used for integrating sipXecs CI with Sipfoundry Crowd

Amazon EC2 Plugin

2.9

Used for starting new Amazon EC2 instances for running nightly builds on

Git Plugin

1.1.1-SNAPSHOT

Used for polling sipXecs repository (- version installed for fixing [http://issues.hudson-ci.org/browse/HUDSON-7547

Instant Messaging Plugin

1.10

Prerequisite for IRC plugin

IRC Plugin

2.7

Used for sending notifications on sipXecs IRC channel

SSH slaves plugin

0.14

Used by master for starting Amazon EC2 image as Hudson slave

General Settings (Manage Hudson > Configure System)

Setting

Value

Description

# of executors

0

no build to be executed on master

Quiet period

5

waits 5 seconds before issuing the build

Security Enabled

Crowd

integrates with Sipxfoundry Crowd Realm

IRC Notifications

enabled

sipXecs_buildbot sends notifications on #sipx channel

Amazon EC2 (used by nightly build only)

 

 

Instance Cap

3

instance will be launched for nightly build only if the number of instances in configured AMI does not exceed 3

Label

nightly

only nightly builds will make use of this feature

Number of executors

1

 

The Amazon EC2 plugin init script (used for system setup and executed after Hudson connects to a new Amazon EC2 instance):

No Format

yum -y install java git* gcc gcc-c++ autoconf automake libtool subversiondoxygen rpm-build
zip httpd-devel openssl-devel jpackage-utils which unzippcre-devel expat-devel unixODBC-devel
createrepo jakarta-commons-beanutilsjakarta-commons-collections jakarta-commons-net ant log4j 
junit ant-commons-loggingant-junit ant-trax ant-nodeps mod_ssl postgresql-server libXp zlib-devel 
postgresql-develruby ruby-devel net-snmp-devel net-snmp-perl libpng-devel libart_lgpl-devel 
freetypefreetype-devel oro scons rpmdevtools redhat-rpm-config alsa-lib-devel 
curl-devel gnutls-devellzo-devel gdbm-devel mysql-devel ncurses-devel python-devel
perl-devel perl-ExtUtils-Embed termcap bind
wget -P /etc/yum.repos.d http://download.sipfoundry.org/pub/sipXecs/sipxecs-rhel-snapshot.repo

yum -y clean all

yum -y install sipx-openfire cgicc-devel java-1.6.0-sun-devel ruby-dbi rubygemsw3c-libwww-devel 
cppunit* ruby-postgres xerces-c-devel jakarta-commons-net nsissipx-freeswitch sipx-jasperreports-deps

gem install -y rake
gem install -y file-tail | installs all needed dependencies

Nightly Build Settings (master-4.2-nightly job)

Setting

Value

Description

Max # of builds to keep

10

only latest 10 build logs / status are available for review

Restrict where this project can be run

nightly

same as label added for Amazon EC2 plugin

Source Code Management

Git

 

Build Triggers

periodically

 

Schedule

@midnight

runs nightly build at midnight

Build, Execute shell step

autoreconf -i
make build

runs autoreconf and invokes make build

Post build actions

 

E-mail notifications sent on failure and success to all recipients within the configured list
(if you want to receive emails with nightly builds status let us know),
IRC notifications (on #sipx channel)

Sanity Build Settings (master-4.2-sanity

...

job)

Setting

Value

Description

Max # of builds to keep

10

only latest 10 build logs / status are available for review

Restrict where this project can be run

ci-slave1.sipfoundry.org

same as label added for preconfigured slave,
sanity builds can run only on this Amazon EC2 instance

Source Code Management

Git, 
URL of repo: git://github.com/dhublerSIPfoundry/sipxecs
Branches to build: master-4.2

 

Build Triggers

Poll SCM

build will be triggered as a result of a new commit

Schedule

@hourly

polls git repo for changes one time per hour

Build, Execute shell step

autoreconf -i
make build

runs autoreconf and invokes make build

Post build actions

 

E-mail notifications sent to commiters before build,
on failure and success to all recipients within the configured list 
(if you want to receive emails with nightly builds status let us know), 
IRC notifications (on #sipx channel)

Other User Actions:

The following actions are available in Hudson console (if you have proper rights)

- Build on demand: If you want to invoke a new build for a given project you can easily accomplish this (if you are in the group of authorized users) within the Hudson administration console. Click on the project name you want to build and proceed with "Build Now" link - a new entry will appear under Build History section. 

- Console Output (available per specific build):

- Display Changes (per project job and per specific build):

Browse Workspace:

Git polling log (available per specific build):