File: NOTES.org

package info (click to toggle)
jenkins-debian-glue 0.20.0
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 380 kB
  • sloc: sh: 2,580; ruby: 485; makefile: 29; python: 24
file content (76 lines) | stat: -rw-r--r-- 2,505 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
* Misc Notes related to Jenkins

This document provides some notes you might consider useful, but aren't necessarily related to jenkins-debian-glue itself.

** Install jenkins.rb on Debian

Goal: Clean installation of https://github.com/cowboyd/jenkins.rb on Debian, using Debian packages.

Recipe provided by Michael Prokop:

#+BEGIN_EXAMPLE
mkdir jenkins-rb.deb ; cd jenkins-rb.deb
gem2deb httparty
gem2deb crack
gem2deb thor
sudo apt-get install libterm-ansicolor-ruby ruby-json libbuilder-ruby
sudo dpkg -i ruby-crack_*.deb  ruby-httparty_*.deb  ruby-jenkins_*.deb  ruby-thor_*.deb
#+END_EXAMPLE

Recipe provided by Michael Gebetsroither:

#+BEGIN_EXAMPLE
git clone git://github.com/gebi/rubyrrdtool.git
cd rubyrrdtool
ruby extconf.rb
make
checkinstall -D --pkgname=rubyrrdtool --maintainer=whatever@example.org --install=no --pkgversion=0.6.0 make install
#+END_EXAMPLE


** Install python-jenkins on Debian

Goal: Clean installation of https://launchpad.net/python-jenkins on Debian, using Debian packages.

Recipe provided by Michael Prokop:

#+BEGIN_EXAMPLE
bzr branch lp:python-jenkins
cd python-jenkins
apt-get install python-stdeb
python setup.py --command-packages=stdeb.command bdist_deb
sudo dpkg -i deb_dist/python-*deb
#+END_EXAMPLE


** Use chroot for building non-Debian stuff

Goal: Do not build stuff on Jenkins Master/Slaves but use a dedicated chroot instead.

Background: Whereas jenkins-debian-glue uses cowbuilder/pbuilder and its separate chroots for building you might want to also build
e.g. documentation without abusing your main build host(s). Using dedicated chroots as slave nodes inside Jenkins provides that.

Set up a basic chroot (e.g. Debian/squeeze):

#+BEGIN_EXAMPLE
debootstrap squeeze /srv/chroot_documentation_builder http://debian.inode.at/debian
wget -O ./make_chroot_jail https://github.com/grml/grml-scripts/raw/master/usr_sbin/make_chroot_jail
bash ./make_chroot_jail chroot-docs /bin/chroot-shell /srv/chroot_documentation_builder
#+END_EXAMPLE

Test the login via SSH running:

  : ssh chroot-docs@localhost

Finally install Java (required for Jenkins) and build-essential (and optionally whatever you might also need):

#+BEGIN_EXAMPLE
chroot /srv/chroot_documentation_builder
mount -t proc none /proc
apt-get install openjdk-6-jre
mkdir /var/lib/jenkins
chown chroot-docs /var/lib/jenkins/
apt-get install build-essential
#+END_EXAMPLE

Then configure a new Slave node in Jenkins using /var/lib/jenkins as $HOME directory and user chroot-docs as login.