Hi,
I'm an old hand at puppet, but new to foreman. I like what I see so far.
The kafo puppet-based installer is a brilliant approach. From my point of
view, it means you can use the same base modules to do interactive,
automated and puppetised installs. Sounds great.
Running the installer from the command line works like a charm.
Supplying answer files works well.
What I've yet to repeatably succeed with is installing and configuring via
puppet.
A one-time install is great, but it seems odd to have to manage the thing
that manages my configurations by hand.
I'm testing on CentOs6.5 boxes.
I'm configuring puppetlabs, epel and scl repos in advance.
I'm trying to do something like:
node 'foreman.local{
include profile::base
include profile::puppetmaster
include profile::foreman
}
class profile::puppet {
include ::puppet
}
class profile::puppetmaster{
include ::puppet
include ::r10k
}
class profile::foreman{
include ::foreman
include ::foreman_proxy
include ::puppet
Class['::foreman'] -> Class['::foreman_proxy'] ->Class['::puppet']
}
The few values I wish to tweak are in hiera:
puppet::server: true
foreman::db_type: mysql
etc…
The ordering in the profile::puppet class is taken from the ordering in
the /usr/share/foreman-installer/config/foreman-installer.yaml file. When
the puppet::server::passenger class is applied before the ruby193 passenger
package installed in foreman::install, the foreman's passenger config
breaks. Trying to preserve this order is hard, though, especially, as I
have calls to ::puppet in base classes that all clients get to manage their
puppet configuration.
I'm at the point of working around this by running foreman-installer in an
exec in a pre-main stage, only trying to manage the puppet configuration
and adding an apache::purge_configs: false to hiera for my puppet server,
to prevent it breaking foreman. I could live with this, but I've now got
problems with the foreman-proxy (something in my config has broken its
gemset).
Has anyone else taken a similar approach and have any tips to share, or is
this an unusual approach to take?
Ben Priestman