blob: fd7121b064fe11bcf6ba3ea2ad5a81e5e95b54ce (
plain)
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
|
Requirements
------------
Your distribution needs a running 'rpm', so on ArchLinux this can be
achieved by installing 'rpm-org'. You also need a running 'yum' which
on ArchLinux you can build from the AUR.
Running
-------
This example runs a single-node biruda installing a Centos 6 image
in a chrooted environment.
Start the node with (as root, because we have to be able to 'chroot'):
biruda -f -c biruda.conf
In another shell start the interactive cli:
shell> biruda -i -c biruda.conf
biruda> status
coordinator eeepc cpe:/o:arch:arch:rolling x86_64 1 alive 1428133209 (0)
worker example_build_gold stopped direct /bin/sh ./build_centos6.sh x86_64 (0)
worker example_run stopped direct /bin/chroot rhel6-x64 /bin/bash -c '/bin/cat /etc/redhat-release' (1)
We see one coordinator running on ArchLinux ('cpe:/o:arch:arch:rolling')
and two workers: 'example_build_gold' builds the image, 'example_run'
runs a command in the chrooted Centos.
We start the first worker by calling:
biruda> start
worker> example_build_gold
Request queued
The 'messages' command shows us the output of the worker:
biruda> messages
output example_build_gold:
1428133254 example_build_gold --- STARTED 19698 ---
1428133255 example_build_gold stderr --2015-04-04 09:40:55-- http://mirror.centos.org/centos/6.6/os/x86_64/Packages/centos-release-6-6.el6.centos.12.2.x86_64.rpm
1428133255 example_build_gold stderr Resolving mirror.centos.org (mirror.centos.org)... 95.211.98.141
..
The daemon spools the output of a worker in a file 'example_build_gold.output',
you can also have a look at that:
shell> tail -f example_build_gold.output
The worker is now running:
biruda> status
coordinator eeepc cpe:/o:arch:arch:rolling x86_64 1 alive 1428134192 (0)
worker example_build_gold running direct /bin/sh ./build_centos6.sh x86_64 (0)
worker example_run stopped direct /bin/chroot rhel6-x64 /bin/bash -c '/bin/cat /etc/redhat-release' (1)
We get the chrooted environment installed in the directory running the biruda
node in 'rhel6-x64':
shell> ls rhel6-x64
bin boot dev etc home lib media mnt opt proc
root sbin selinux srv sys tmp usr var
When the installation has finished we can run the other worker which just
makes a cat of the Redhat version file '/etc/redhat-release':
biruda> start
worker> example_run
Request queued
biruda> messages
CentOS release 6.6 (Final)
biruda>
|