Commit a34ca690 authored by Georgios Gousios's avatar Georgios Gousios
Browse files

Instructions on how to setup Jenkins for CI

parent feec8f0e
......@@ -7,6 +7,8 @@ web application.
-README.develop: for information on how to setup a development environment
-README.deploy : for information on how to deploy the application : for information on how to setup a Jenkins-based
continuous integration system
-README.i18n : for information on application internationalization
Continuous integration with Jenkins
The following instructions will setup Jenkins to run synnefo tests with
the SQLite database. To run the tests on MySQL and/or Postgres, step 4
must be replicated. Also, the correct configuration file must be copied
(line 5 of the build script).
1. Install and start Jenkins. On Debian:
wget -q -O - | sudo apt-key add -
echo "deb binary/" >>/etc/apt/sources.list
sudo apt-get update
sudo apt-get install jenkins
2. After Jenkins starts, go to
and install the following plug-ins at
-Jenkins Cobertura Plugin
-Jenkins Email Extension Plugin
-Jenkins GIT plugin
-Jenkins SLOCCount Plug-in
-Hudson/Jenkins Violations plugin
3. Make sure that all system-level dependencies specified in README.develop
are correctly installed
4. Create a new "free-style software" job and set the following values:
-Project name: synnefo
-Source Code Management: Git
-URL of repository: Jenkins Git does not support HTTPS for checking out
directly from the repository. The temporary solution
is to checkout with a cron script in a directory and
set the checkout path in this field
-Branches to build: master and perhaps others
-Git->Advanced->Local subdirectory for repo (optional): synnefo
-Git->Advanced->Prune remote branches before build: check
-Repository browser: redmineweb,
-Build Triggers->Poll SCM: check
Schedule: # every ten minutes
10 * * * *
-Build -> Add build step-> Execute shell
#!/bin/bash -ex
cd synnefo
/usr/bin/sloccount --duplicates --wide --details api util ui logic auth > reports/
cp conf/ci/ .
if [ ! -e requirements.pip ]; then cp conf/ci/pip-1.2.conf requirements.pip; fi
cp conf/ci/
python update_ve
python hudson api db logic
-Post-build Actions->Publish JUnit test result report: check
Test report XMLs: synnefo/reports/TEST-*.xml
-Post-build Actions->Publish Cobertura Coverage Report: check
Cobertura xml report pattern: synnefo/reports/coverage.xml
-Post-build Actions->Report Violations: check
pylint[XML filename pattern]: synnefo/reports/
-Post-build Actions->Publish SLOCCount analysis results
SLOCCount reports: synnefo/reports/
(also, remember to install sloccount at /usr/bin)
See also:
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment