Project

General

Profile

RPM's distribution based installation » History » Revision 30

Revision 29 (Rytis Sileika, 08/01/2012 10:19 AM) → Revision 30/31 (Sam Kottler, 12/10/2012 04:51 PM)

h1. RPM's distribution based installation 

 We maintain a repository for RHEL and Fedora (and clones) - you may add it via: 

 h2. Release 

 1.) For RHEL 6 ensure your system is subscribed to EPEL.  

 For RHEL 5 you will need to be subscribed to both EPEL and the RHEL Virtualization RHN Channel. 
 Also be advised, that on RHEL5 the Foreman Repo will update Ruby to version 1.8.7. This has  
 the potential to break stuff (like passenger, notes on getting it working again below),  
 so be sure you want to proceed before committing to the installation. 

 <pre> 
 http://fedoraproject.org/wiki/EPEL 
 </pre> 

 2.) Install the foreman-release.rpm for your version of RHEL or Fedora 
 <pre> 
 http://yum.theforeman.org/releases/1.0/el5/foreman-release.rpm 
 http://yum.theforeman.org/releases/1.0/el6/foreman-release.rpm 
 http://yum.theforeman.org/releases/1.0/f16/foreman-release.rpm 
 http://yum.theforeman.org/releases/1.0/f17/foreman-release.rpm 
 </pre> 

 3.) Install foreman and other foreman-* packages to add functionality: 
 <pre> 
 foreman                 Foreman server 
 foreman-proxy           Foreman Smart Proxy 
 foreman-cli             Foreman CLI utility 
 foreman-libvirt         libvirt provisioning support 
 foreman-ovirt           ovirt/RHEV provisioning support 
 foreman-ec2             EC2 provisioning support 
 foreman-vmware          VMware provisioning support 
 foreman-console         Console additions 
 foreman-mysql           MySQL database support 
 foreman-mysql2          MySQL database support 
 foreman-postgresql      PostgreSQL database support 
 foreman-sqlite          SQLite database support 
 foreman-test            Testing support (dependency rpm's not built yet) 
 foreman-devel           Development support (dependency rpm's not built yet) 
 </pre> 

 5.) Configure 
 <pre> 
 Edit /etc/foreman/settings.yaml and /etc/foreman/database.yml 
 su - foreman -s /bin/bash -c /usr/share/foreman/extras/dbmigrate 
 </pre> 

 6.) Start the foreman service or set up passenger 
 <pre> 
 service foreman start 
 </pre> 

 7.) Set up Nginx + Passenger 

 [[Setting up Nginx + Passenger ]] 

 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.  
 After foreman is installed ensure /usr/sbin is in your path so that the axps binary can be found, otherwise the rpm's may  
 fail to build while complaining about being unable to find some files. Then do the following: 
 <pre> 
 yum localinstall http://passenger.stealthymonkeys.com/rhel/5/x86_64/rubygem-daemon_controller-0.2.5-1.noarch.rpm 
 wget http://passenger.stealthymonkeys.com/SRPMS/rubygem-passenger-3.0.12-1.src.rpm  
 yum-builddep rubygem-passenger-3.0.12-1.src.rpm  
 rpmbuild --rebuild rubygem-passenger-3.0.12-1.src.rpm 
 </pre> 

 h2. Development 

 1.) For RHEL 5 & 6 ensure your system is subscribed to EPEL.  

 For RHEL 5 you will need to be subscribed to both EPEL and the RHEL Virtualization RHN Channel. 
 Also be advised, that on RHEL5 the Foreman Repo will update Ruby to version 1.8.7. This has  
 the potential to break stuff (like passenger, notes on getting it working again below),  
 so be sure you want to proceed before committing to the installation. 

 <pre> 
 http://fedoraproject.org/wiki/EPEL 
 </pre> 

 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. Fedora 
 <pre> 
 http://yum.theforeman.org/rc/el5/foreman-release.rpm http://yum.theforeman.org/development/el5/foreman-release.rpm 
 http://yum.theforeman.org/rc/el6/foreman-release.rpm http://yum.theforeman.org/development/el6/foreman-release.rpm 
 http://yum.theforeman.org/rc/f16/foreman-release.rpm http://yum.theforeman.org/development/f16/foreman-release.rpm 
 http://yum.theforeman.org/rc/f17/foreman-release.rpm http://yum.theforeman.org/development/f17/foreman-release.rpm 
 </pre> 

 3.) Install foreman and other foreman-* packages to add functionality: 
 <pre> 
 foreman                 Foreman server 
 foreman-proxy           Foreman Smart Proxy 
 foreman-cli             Foreman CLI utility 
 foreman-libvirt         libvirt provisioning support 
 foreman-ovirt           ovirt/RHEV provisioning support 
 foreman-ec2             EC2 provisioning support 
 foreman-vmware          VMware provisioning support 
 foreman-console         Console additions 
 foreman-mysql           MySQL database support 
 foreman-mysql2          MySQL database support 
 foreman-postgresql      PostgreSQL database support 
 foreman-sqlite          SQLite database support 
 foreman-test            Testing support (dependency rpm's not built yet) 
 foreman-devel           Development support (dependency rpm's not built yet) 
 </pre> 

 5.) Configure 
 <pre> 
 Edit /etc/foreman/settings.yaml and /etc/foreman/database.yml 
 su - foreman -s /bin/bash -c /usr/share/foreman/extras/dbmigrate 
 </pre> 

 6.) Start the foreman service or set up passenger 
 <pre> 
 service foreman start 
 </pre> 
 Or: 

 Passenger packages/repos are available at http://passenger.stealthymonkeys.com/ 

 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.  
 After foreman is installed ensure /usr/sbin is in your path so that the axps binary can be found, otherwise the rpm's may  
 fail to build while complaining about being unable to find some files. Then do the following: 
 <pre> 
 yum localinstall http://passenger.stealthymonkeys.com/rhel/5/x86_64/rubygem-daemon_controller-0.2.5-1.noarch.rpm 
 wget http://passenger.stealthymonkeys.com/SRPMS/rubygem-passenger-3.0.12-1.src.rpm  
 yum-builddep rubygem-passenger-3.0.12-1.src.rpm  
 rpmbuild --rebuild rubygem-passenger-3.0.12-1.src.rpm 
 </pre> 

 h2. Nightly Builds 

 Create a /etc/yum.repos.d/foreman-nightly.repo with the following contents: 
 el5: 
 <pre> 
 [foreman-nightly] 
 name=foreman-nightly 
 baseurl=http://yum.theforeman.org/nightly/el5/$basearch 
 gpgcheck=0 
 enabled=1 

 [foreman-nightly-source] 
 name=foreman-nightly 
 baseurl=http://yum.theforeman.org/nightly/el5/source 
 gpgcheck=0 
 enabled=0 
 </pre> 

 el6: 
 <pre> 
 [foreman-nightly] 
 name=foreman-nightly 
 baseurl=http://yum.theforeman.org/nightly/el6/$basearch 
 gpgcheck=0 
 enabled=1 

 [foreman-nightly-source] 
 name=foreman-nightly 
 baseurl=http://yum.theforeman.org/nightly/el6/source 
 gpgcheck=0 
 enabled=0 
 </pre> 

 f16: 
 <pre> 
 [foreman-nightly] 
 name=foreman-nightly 
 baseurl=http://yum.theforeman.org/nightly/f16/$basearch 
 gpgcheck=0 
 enabled=1 

 [foreman-nightly-source] 
 name=foreman-nightly 
 baseurl=http://yum.theforeman.org/nightly/f16/source 
 gpgcheck=0 
 enabled=0 
 </pre> 

 f17: 
 <pre> 
 [foreman-nightly] 
 name=foreman-nightly 
 baseurl=http://yum.theforeman.org/nightly/f17/$basearch 
 gpgcheck=0 
 enabled=1 

 [foreman-nightly-source] 
 name=foreman-nightly 
 baseurl=http://yum.theforeman.org/nightly/f17/source 
 gpgcheck=0 
 enabled=0 
 </pre> 

 h2. Getting the RPMS 

 If you just want to get the rpms: 

 http://yum.theforeman.org