Project

General

Profile

RPM's distribution based installation » History » Version 30

Sam Kottler, 12/10/2012 04:51 PM

1 1 Romain Vrignaud
h1. RPM's distribution based installation
2
3
We maintain a repository for RHEL and Fedora (and clones) - you may add it via:
4
5 23 Anonymous
h2. Release
6 1 Romain Vrignaud
7 24 Anonymous
1.) For RHEL 6 ensure your system is subscribed to EPEL. 
8
9
For RHEL 5 you will need to be subscribed to both EPEL and the RHEL Virtualization RHN Channel.
10
Also be advised, that on RHEL5 the Foreman Repo will update Ruby to version 1.8.7. This has 
11
the potential to break stuff (like passenger, notes on getting it working again below), 
12
so be sure you want to proceed before committing to the installation.
13
14
<pre>
15
http://fedoraproject.org/wiki/EPEL
16
</pre>
17
18
2.) Install the foreman-release.rpm for your version of RHEL or Fedora
19
<pre>
20 25 Anonymous
http://yum.theforeman.org/releases/1.0/el5/foreman-release.rpm
21
http://yum.theforeman.org/releases/1.0/el6/foreman-release.rpm
22
http://yum.theforeman.org/releases/1.0/f16/foreman-release.rpm
23
http://yum.theforeman.org/releases/1.0/f17/foreman-release.rpm
24 24 Anonymous
</pre>
25
26
3.) Install foreman and other foreman-* packages to add functionality:
27
<pre>
28
foreman               Foreman server
29
foreman-proxy         Foreman Smart Proxy
30
foreman-cli           Foreman CLI utility
31
foreman-libvirt       libvirt provisioning support
32
foreman-ovirt         ovirt/RHEV provisioning support
33
foreman-ec2           EC2 provisioning support
34
foreman-vmware        VMware provisioning support
35
foreman-console       Console additions
36
foreman-mysql         MySQL database support
37
foreman-mysql2        MySQL database support
38
foreman-postgresql    PostgreSQL database support
39
foreman-sqlite        SQLite database support
40
foreman-test          Testing support (dependency rpm's not built yet)
41
foreman-devel         Development support (dependency rpm's not built yet)
42
</pre>
43
44
5.) Configure
45
<pre>
46
Edit /etc/foreman/settings.yaml and /etc/foreman/database.yml
47
su - foreman -s /bin/bash -c /usr/share/foreman/extras/dbmigrate
48
</pre>
49
50
6.) Start the foreman service or set up passenger
51
<pre>
52
service foreman start
53
</pre>
54 1 Romain Vrignaud
55 26 Rytis Sileika
7.) Set up Nginx + Passenger
56
57 29 Rytis Sileika
[[Setting up Nginx + Passenger ]]
58 24 Anonymous
59
On RHEL5 the RPM's at the URL above will not run after updating ruby. Fortunately it is fairly easy to get it working again. 
60
After foreman is installed ensure /usr/sbin is in your path so that the axps binary can be found, otherwise the rpm's may 
61
fail to build while complaining about being unable to find some files. Then do the following:
62
<pre>
63
yum localinstall http://passenger.stealthymonkeys.com/rhel/5/x86_64/rubygem-daemon_controller-0.2.5-1.noarch.rpm
64
wget http://passenger.stealthymonkeys.com/SRPMS/rubygem-passenger-3.0.12-1.src.rpm 
65
yum-builddep rubygem-passenger-3.0.12-1.src.rpm 
66
rpmbuild --rebuild rubygem-passenger-3.0.12-1.src.rpm
67
</pre>
68
69 2 Anonymous
h2. Development
70 1 Romain Vrignaud
71 30 Sam Kottler
1.) For RHEL 5 & 6 ensure your system is subscribed to EPEL. 
72 19 Anonymous
73
For RHEL 5 you will need to be subscribed to both EPEL and the RHEL Virtualization RHN Channel.
74
Also be advised, that on RHEL5 the Foreman Repo will update Ruby to version 1.8.7. This has 
75 20 Anonymous
the potential to break stuff (like passenger, notes on getting it working again below), 
76 19 Anonymous
so be sure you want to proceed before committing to the installation.
77
78 2 Anonymous
<pre>
79
http://fedoraproject.org/wiki/EPEL
80 1 Romain Vrignaud
</pre>
81 14 Anonymous
82 30 Sam Kottler
2.) Install the foreman-release.rpm for your version of RHEL or Fedora. This will only work when there is an RC that is in the repository for testing.
83 1 Romain Vrignaud
<pre>
84 30 Sam Kottler
http://yum.theforeman.org/rc/el5/foreman-release.rpm
85
http://yum.theforeman.org/rc/el6/foreman-release.rpm
86
http://yum.theforeman.org/rc/f16/foreman-release.rpm
87
http://yum.theforeman.org/rc/f17/foreman-release.rpm
88 2 Anonymous
</pre>
89 1 Romain Vrignaud
90 2 Anonymous
3.) Install foreman and other foreman-* packages to add functionality:
91 3 Anonymous
<pre>
92 7 Anonymous
foreman               Foreman server
93
foreman-proxy         Foreman Smart Proxy
94
foreman-cli           Foreman CLI utility
95
foreman-libvirt       libvirt provisioning support
96
foreman-ovirt         ovirt/RHEV provisioning support
97 12 Anonymous
foreman-ec2           EC2 provisioning support
98 7 Anonymous
foreman-vmware        VMware provisioning support
99
foreman-console       Console additions
100
foreman-mysql         MySQL database support
101
foreman-mysql2        MySQL database support
102
foreman-postgresql    PostgreSQL database support
103
foreman-sqlite        SQLite database support
104
foreman-test          Testing support (dependency rpm's not built yet)
105
foreman-devel         Development support (dependency rpm's not built yet)
106 2 Anonymous
</pre>
107
108
5.) Configure
109
<pre>
110
Edit /etc/foreman/settings.yaml and /etc/foreman/database.yml
111 9 Anonymous
su - foreman -s /bin/bash -c /usr/share/foreman/extras/dbmigrate
112 2 Anonymous
</pre>
113
114
6.) Start the foreman service or set up passenger
115
<pre>
116
service foreman start
117 21 Anonymous
</pre>
118 16 Anonymous
Or:
119
120 1 Romain Vrignaud
Passenger packages/repos are available at http://passenger.stealthymonkeys.com/
121 21 Anonymous
122
On RHEL5 the RPM's at the URL above will not run after updating ruby. Fortunately it is fairly easy to get it working again. 
123
After foreman is installed ensure /usr/sbin is in your path so that the axps binary can be found, otherwise the rpm's may 
124
fail to build while complaining about being unable to find some files. Then do the following:
125
<pre>
126 16 Anonymous
yum localinstall http://passenger.stealthymonkeys.com/rhel/5/x86_64/rubygem-daemon_controller-0.2.5-1.noarch.rpm
127 18 Anonymous
wget http://passenger.stealthymonkeys.com/SRPMS/rubygem-passenger-3.0.12-1.src.rpm 
128 2 Anonymous
yum-builddep rubygem-passenger-3.0.12-1.src.rpm 
129 1 Romain Vrignaud
rpmbuild --rebuild rubygem-passenger-3.0.12-1.src.rpm
130 15 Anonymous
</pre>
131
132 22 Anonymous
h2. Nightly Builds
133
134
Create a /etc/yum.repos.d/foreman-nightly.repo with the following contents:
135
el5:
136
<pre>
137
[foreman-nightly]
138
name=foreman-nightly
139
baseurl=http://yum.theforeman.org/nightly/el5/$basearch
140
gpgcheck=0
141
enabled=1
142
143
[foreman-nightly-source]
144
name=foreman-nightly
145
baseurl=http://yum.theforeman.org/nightly/el5/source
146
gpgcheck=0
147
enabled=0
148
</pre>
149
150
el6:
151
<pre>
152
[foreman-nightly]
153
name=foreman-nightly
154
baseurl=http://yum.theforeman.org/nightly/el6/$basearch
155
gpgcheck=0
156
enabled=1
157
158
[foreman-nightly-source]
159
name=foreman-nightly
160
baseurl=http://yum.theforeman.org/nightly/el6/source
161
gpgcheck=0
162
enabled=0
163
</pre>
164
165
f16:
166
<pre>
167
[foreman-nightly]
168
name=foreman-nightly
169
baseurl=http://yum.theforeman.org/nightly/f16/$basearch
170
gpgcheck=0
171
enabled=1
172
173
[foreman-nightly-source]
174
name=foreman-nightly
175
baseurl=http://yum.theforeman.org/nightly/f16/source
176
gpgcheck=0
177
enabled=0
178
</pre>
179
180
f17:
181
<pre>
182
[foreman-nightly]
183
name=foreman-nightly
184
baseurl=http://yum.theforeman.org/nightly/f17/$basearch
185
gpgcheck=0
186
enabled=1
187
188
[foreman-nightly-source]
189
name=foreman-nightly
190
baseurl=http://yum.theforeman.org/nightly/f17/source
191
gpgcheck=0
192
enabled=0
193
</pre>
194
195 1 Romain Vrignaud
h2. Getting the RPMS
196 6 Anonymous
197 1 Romain Vrignaud
If you just want to get the rpms:
198 6 Anonymous
199 1 Romain Vrignaud
http://yum.theforeman.org