RPM's distribution based installation » History » Version 21
Anonymous, 07/03/2012 11:24 AM
| 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 | 2 | Anonymous | h2. Stable |
| 6 | |||
| 7 | 1 | Romain Vrignaud | h3. Puppet |
| 8 | |||
| 9 | <pre> |
||
| 10 | yumrepo { 'foreman': |
||
| 11 | descr => 'Foreman Repo', |
||
| 12 | baseurl => 'http://yum.theforeman.org/stable', |
||
| 13 | gpgcheck => '0', |
||
| 14 | enabled => '1' |
||
| 15 | } |
||
| 16 | </pre> |
||
| 17 | |||
| 18 | h3. Quick and dirty |
||
| 19 | |||
| 20 | <pre> |
||
| 21 | cat > /etc/yum.repos.d/foreman.repo << EOF |
||
| 22 | [foreman] |
||
| 23 | name=Foreman Repo |
||
| 24 | baseurl=http://yum.theforeman.org/stable |
||
| 25 | gpgcheck=0 |
||
| 26 | enabled=1 |
||
| 27 | EOF |
||
| 28 | </pre> |
||
| 29 | |||
| 30 | <pre> |
||
| 31 | yum install foreman |
||
| 32 | </pre> |
||
| 33 | |||
| 34 | |||
| 35 | 2 | Anonymous | h2. Development |
| 36 | 1 | Romain Vrignaud | |
| 37 | 19 | Anonymous | 1.) For RHEL 6 ensure your system is subscribed to EPEL. |
| 38 | |||
| 39 | For RHEL 5 you will need to be subscribed to both EPEL and the RHEL Virtualization RHN Channel. |
||
| 40 | Also be advised, that on RHEL5 the Foreman Repo will update Ruby to version 1.8.7. This has |
||
| 41 | 20 | Anonymous | the potential to break stuff (like passenger, notes on getting it working again below), |
| 42 | 19 | Anonymous | so be sure you want to proceed before committing to the installation. |
| 43 | |||
| 44 | 2 | Anonymous | <pre> |
| 45 | http://fedoraproject.org/wiki/EPEL |
||
| 46 | </pre> |
||
| 47 | 1 | Romain Vrignaud | |
| 48 | 14 | Anonymous | |
| 49 | 11 | Anonymous | 2.) Install the foreman-release.rpm for your version of RHEL or Fedora |
| 50 | 1 | Romain Vrignaud | <pre> |
| 51 | 14 | Anonymous | http://yum.theforeman.org/development/el5/foreman-release.rpm |
| 52 | 5 | Anonymous | http://yum.theforeman.org/development/el6/foreman-release.rpm |
| 53 | http://yum.theforeman.org/development/f16/foreman-release.rpm |
||
| 54 | http://yum.theforeman.org/development/f17/foreman-release.rpm |
||
| 55 | 2 | Anonymous | </pre> |
| 56 | 1 | Romain Vrignaud | |
| 57 | 2 | Anonymous | 3.) Install foreman and other foreman-* packages to add functionality: |
| 58 | 3 | Anonymous | <pre> |
| 59 | 7 | Anonymous | foreman Foreman server |
| 60 | foreman-proxy Foreman Smart Proxy |
||
| 61 | foreman-cli Foreman CLI utility |
||
| 62 | foreman-libvirt libvirt provisioning support |
||
| 63 | foreman-ovirt ovirt/RHEV provisioning support |
||
| 64 | 12 | Anonymous | foreman-ec2 EC2 provisioning support |
| 65 | 7 | Anonymous | foreman-vmware VMware provisioning support |
| 66 | foreman-console Console additions |
||
| 67 | foreman-mysql MySQL database support |
||
| 68 | foreman-mysql2 MySQL database support |
||
| 69 | foreman-postgresql PostgreSQL database support |
||
| 70 | foreman-sqlite SQLite database support |
||
| 71 | foreman-test Testing support (dependency rpm's not built yet) |
||
| 72 | foreman-devel Development support (dependency rpm's not built yet) |
||
| 73 | 2 | Anonymous | </pre> |
| 74 | |||
| 75 | 5.) Configure |
||
| 76 | <pre> |
||
| 77 | Edit /etc/foreman/settings.yaml and /etc/foreman/database.yml |
||
| 78 | 9 | Anonymous | su - foreman -s /bin/bash -c /usr/share/foreman/extras/dbmigrate |
| 79 | 2 | Anonymous | </pre> |
| 80 | |||
| 81 | 6.) Start the foreman service or set up passenger |
||
| 82 | <pre> |
||
| 83 | service foreman start |
||
| 84 | 21 | Anonymous | </pre> |
| 85 | 16 | Anonymous | Or: |
| 86 | |||
| 87 | 1 | Romain Vrignaud | Passenger packages/repos are available at http://passenger.stealthymonkeys.com/ |
| 88 | 21 | Anonymous | |
| 89 | 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. |
||
| 90 | After foreman is installed ensure /usr/sbin is in your path so that the axps binary can be found, otherwise the rpm's may |
||
| 91 | fail to build while complaining about being unable to find some files. Then do the following: |
||
| 92 | <pre> |
||
| 93 | 16 | Anonymous | yum localinstall http://passenger.stealthymonkeys.com/rhel/5/x86_64/rubygem-daemon_controller-0.2.5-1.noarch.rpm |
| 94 | 18 | Anonymous | wget http://passenger.stealthymonkeys.com/SRPMS/rubygem-passenger-3.0.12-1.src.rpm |
| 95 | yum-builddep rubygem-passenger-3.0.12-1.src.rpm |
||
| 96 | rpmbuild --rebuild rubygem-passenger-3.0.12-1.src.rpm |
||
| 97 | 2 | Anonymous | </pre> |
| 98 | |||
| 99 | Example RHEL6 setup: |
||
| 100 | 6 | Anonymous | <pre> |
| 101 | 1 | Romain Vrignaud | yum install http://mirror.symnds.com/distributions/fedora-epel/6/i386/epel-release-6-7.noarch.rpm |
| 102 | 6 | Anonymous | yum install http://yum.theforeman.org/development/el6/foreman-release.rpm |
| 103 | 18 | Anonymous | yum install foreman foreman-proxy foreman-ovirt foreman-sqlite foreman-ec2 foreman-console foreman-libvirt foreman-vmware |
| 104 | 2 | Anonymous | vi /etc/settings/settings.yaml /etc/settings/database.yml |
| 105 | 1 | Romain Vrignaud | su - foreman -s /bin/bash -c /usr/share/foreman/extras/dbmigrate |
| 106 | 15 | Anonymous | </pre> |
| 107 | |||
| 108 | 1 | Romain Vrignaud | h2. Getting the RPMS |
| 109 | 6 | Anonymous | |
| 110 | 1 | Romain Vrignaud | If you just want to get the rpms: |
| 111 | 6 | Anonymous | |
| 112 | 1 | Romain Vrignaud | http://yum.theforeman.org |