Project

General

Profile

Debian-Ubuntu installation by packages » History » Version 8

Greg Sutcliffe, 08/05/2012 08:01 AM

1 1 Romain Vrignaud
h1. Debian-Ubuntu installation by packages
2
3 3 Greg Sutcliffe
{{toc}}
4 1 Romain Vrignaud
5
The Foreman packages should work on the following Debian-based Linux distributions:
6
7 3 Greg Sutcliffe
h2. Distributions
8
9 1 Romain Vrignaud
* Debian Linux 6.0 (Squeeze)
10 8 Greg Sutcliffe
* Ubuntu Linux 12.04 LTS   (32bit 12.04 has some problems with native libraries at the moment - "Ubuntu":http://theforeman.org/projects/foreman/wiki/Debian-Ubuntu_installation_by_packages/#Issues-with-Ubuntu)
11 5 Greg Sutcliffe
12
Foreman might still work on these distros, but it has not been tested:
13 1 Romain Vrignaud
14 5 Greg Sutcliffe
* Debian Linux 5.0 (Lenny)
15 7 Greg Sutcliffe
* Ubuntu Linux 11.04
16 3 Greg Sutcliffe
* Ubuntu Linux 10.10
17 1 Romain Vrignaud
18 6 David Swift
If you encounter any errors during the installation, "please file a bug report!":http://theforeman.org/projects/foreman/issues/new
19 1 Romain Vrignaud
20 3 Greg Sutcliffe
h2. Apt Configuration
21 1 Romain Vrignaud
22
Add one of the following lines to your @/etc/apt/sources.list@ (alternatively in a separate file in @/etc/apt/sources.list.d/foreman.list@):
23
24
<pre>
25
# Stable packages
26
deb http://deb.theforeman.org/ stable main
27
28
# Testing packages
29
deb http://deb.theforeman.org/ testing main
30
31
# Nightly builds. Beware: HERE BE DRAGONS
32
deb http://deb.theforeman.org/ nightly main
33
</pre>
34
35
The public key for "secure APT":http://wiki.debian.org/SecureApt can be downloaded "here":http://deb.theforeman.org/foreman.asc
36
37
You can add this key with
38
<pre>
39
apt-key add foreman.asc
40
</pre>
41
42
or combine downloading and registering:
43
<pre>
44
wget -q http://deb.theforeman.org/foreman.asc -O- | apt-key add -
45
</pre>
46
47
The key fingerprint is
48
<pre>
49
1DCB 15D1 2CA1 40EE F494  7E57 66CF 053F E775 FF07
50 3 Greg Sutcliffe
Foreman Archive Signing Key <packages@theforeman.org>
51 1 Romain Vrignaud
</pre>
52
53 5 Greg Sutcliffe
Remember to update your package lists!
54 1 Romain Vrignaud
55
<pre>
56 5 Greg Sutcliffe
apt-get update
57 1 Romain Vrignaud
</pre>
58
59 5 Greg Sutcliffe
h2. Install packages
60 1 Romain Vrignaud
61 5 Greg Sutcliffe
The packages are now split by gem dependencies - there are 11 foreman* packages to choose from. These are:
62 1 Romain Vrignaud
63 3 Greg Sutcliffe
Main package
64
* foreman
65
66
Database gems - you need at least one of these
67
* foreman-sqlite3
68
* foreman-mysql2
69
* foreman-mysql
70
* foreman-pgsql
71
72
Optional functionality
73
* foreman-console
74
* foreman-fog
75
* foreman-libvirt
76
* foreman-ovirt
77 1 Romain Vrignaud
* foreman-test
78 3 Greg Sutcliffe
* foreman-vmware
79 1 Romain Vrignaud
80 3 Greg Sutcliffe
Installation instructions are:
81 1 Romain Vrignaud
<pre>
82
# Install packages  (adjust additional packages as needed)
83
apt-get install foreman foreman-sqlite3 foreman-libvirt
84
85 3 Greg Sutcliffe
# Copy sample db config to /etc
86 1 Romain Vrignaud
cp /usr/share/foreman/config/database.yml.example /etc/foreman/database.yml
87
88
# Review settings and DB config
89 3 Greg Sutcliffe
vi /etc/settings/settings.yaml /etc/foreman/database.yml
90
91
# Perform initial DB setup
92
su - foreman -s /bin/bash -c /usr/share/foreman/extras/dbmigrate
93
</pre>
94 4 Greg Sutcliffe
95 1 Romain Vrignaud
The packages should auto-run db:migrate if @/etc/foreman/database.yml@ exists. So the initial db:migrate is only needed during first install, upgrades should just work.
96 8 Greg Sutcliffe
97
h3. Issues with Ubuntu
98
99
Presently Ubuntu12.04 has a couple of issues. Firstly, it already contains some of the libraries we require, but at newer versions than we can use. As such, you may need to downgrade them if they are already installed. This applies to both 64bit and 32bit.
100
101
32-bit Ubuntu has significant errors to do with native libraries, which we have not yet been able to track down yet. The native-arch packages (such as ruby-libvirt or ruby-sqlite3) will install but will not actually be usable. The simplest fix to this is to do "gem install sqlite3" (or whatever the broken gem is) which should fix the issue.
102
103
We will look into providing a separate Ubuntu repository at some point in the future when we can provide packages dedicated to solving these issues.
104 3 Greg Sutcliffe
105 5 Greg Sutcliffe
h2. Upgrading from 0.4.2
106 3 Greg Sutcliffe
107 5 Greg Sutcliffe
Upgrading from 0.4.2 to 1.0 has been tested on Debian 6 (32 and 64 bit) and we expect that simply upgrading should work fine:
108 4 Greg Sutcliffe
109 5 Greg Sutcliffe
<pre>
110
apt-get update
111
apt-get dist-upgrade
112
</pre>
113 3 Greg Sutcliffe
114 5 Greg Sutcliffe
The packages include a db:migrate, so your database will be migrated too. However, please note the new split-package architecture - you may want check and see if any of the new dependencies fit your usecase(s).
115
116
<pre>apt-cache search foreman</pre>