I have been using The Foreman as a front end for Puppet Open Source for a little while, I barely even scratch the surface of its features, but it has made my life easier as an ENC.
Previously I had been using it on Ubuntu without an issue. But we have now moved to using RHEL based systems so I had to get it up an running on a fresh CentOS 7 system. As we run a pretty basic setup, we have everything in one box, that is foreman, puppet master, puppet ca and the puppet postgresdb.
There are good installation instructions on The Foreman’s website however I kept hitting a brick wall when trying to install.
I would follow the instructions to the letter, yet everytime I would receive the following errors:
/Stage[main]/Foreman_proxy::Register/Foreman_smartproxy[myserver.test.internal]: Could not evaluate: Could not load data from https://myserver.test.internal /Stage[main]/Foreman_proxy::Register/Foreman_smartproxy[myserver.test.internal]: Failed to call refresh: Could not load data from https://myserver.test.internal /Stage[main]/Foreman_proxy::Register/Foreman_smartproxy[myserver.test.internal]: Could not load data from https://myserver.test.internal
After a fair bit of hair pulling I found that if you install puppet server first, before running the foreman-installer, and then if you explicitly specify the option
--enable-foreman-proxy then the installation completes successfully. I have copied the installation steps from The Foreman quick start guide below, and have included the
--enable-foreman-proxy option so you can easily follow along.
Installation steps for CentOS 7 (Taken from The Foreman quick start guide)
Using a recent version of Puppet is recommended, which is available from the Puppet Labs repository. You may skip this and use the older version from EPEL without a problem, however it has reduced community support.
rpm -ivh http://yum.puppetlabs.com/puppetlabs-release-el-7.noarch.rpm
Enable the EPEL (Extra Packages for Enterprise Linux) and the Foreman repos:
yum -y install epel-release http://yum.theforeman.org/releases/1.7/el7/x86_64/foreman-release.rpm
Downloading the installer
yum -y install foreman-installer
Install Puppet Server
yum install puppet-server reboot
Running the installer
The installation run is non-interactive, but the configuration can be customized by supplying any of the options listed in
foreman-installer --help, or by running
foreman-installer -i for interactive mode. More examples are given in the Installation Options section. Adding
-v will disable the progress bar and display all changes. To run the installer, execute: