Project

General

Profile

Initial setup » History » Version 1

Romain Vrignaud, 11/17/2011 08:58 AM

1 1 Romain Vrignaud
h1. Initial setup
2 1 Romain Vrignaud
3 1 Romain Vrignaud
h2. Configuration
4 1 Romain Vrignaud
5 1 Romain Vrignaud
Foreman configuration is managed from two places; a configuration file *config/settings.yaml* and from the *SETTINGS/Foreman Settings* page. A full description of the configuration options is given [[foreman_configuration|here]]
6 1 Romain Vrignaud
7 1 Romain Vrignaud
h2. Database
8 1 Romain Vrignaud
9 1 Romain Vrignaud
Foreman uses a database, this database can be shared with Puppet store-configs (they are compatible, as Foreman extends the puppet database schema).
10 1 Romain Vrignaud
By default, SQLite is used, if you want to use other database (e.g. [[FAQ#I-want-to-use-MySQL|MySQL]]) please modify the configuration file under +config/database.yml+.
11 1 Romain Vrignaud
12 1 Romain Vrignaud
If you want to share the database with Puppets (storeconfig), just modify +config/database.yml+ to point to the same database configuration as puppet is.
13 1 Romain Vrignaud
14 1 Romain Vrignaud
In both cases, please use the *production* settings.
15 1 Romain Vrignaud
16 1 Romain Vrignaud
to initialize the database schema type:
17 1 Romain Vrignaud
<pre>
18 1 Romain Vrignaud
cd <foreman installation path> && RAILS_ENV=production rake db:migrate
19 1 Romain Vrignaud
</pre>
20 1 Romain Vrignaud
21 1 Romain Vrignaud
h2. Import Data from Puppet
22 1 Romain Vrignaud
23 1 Romain Vrignaud
At this point, you might want to go through the [[FAQ]] to see how can you import your data into Foreman.
24 1 Romain Vrignaud
25 1 Romain Vrignaud
h2. Start The Web Server
26 1 Romain Vrignaud
27 1 Romain Vrignaud
if you installed via rpm, just start the foreman service, or start the built in web server by typing:
28 1 Romain Vrignaud
<code>./script/server -e production</code>
29 1 Romain Vrignaud
30 1 Romain Vrignaud
and point your browser to http://foreman:3000
31 1 Romain Vrignaud
32 1 Romain Vrignaud
If you would like to keep the server running, its recommend to setup passenger or use the RPM.
33 1 Romain Vrignaud
example usage with passenger can be found here: http://github.com/ohadlevy/puppet-foreman/blob/master/foreman/templates/foreman-vhost.conf.erb
34 1 Romain Vrignaud
35 1 Romain Vrignaud
h2. Getting your Puppet Reports into Foreman
36 1 Romain Vrignaud
37 1 Romain Vrignaud
Read [[Puppet_Reports]] to learn how to get your nodes to report to Foreman.