Add FQDN hostname and IP address
echo '10.10.10.10 vmpuppet1.domain.local puppet' >> /etc/hosts
Set FQDN as hostname
sudo hostnamectl set-hostname vmpuppet1.domain.local
Add RPM repos
sudo rpm -ivh https://yum.puppetlabs.com/puppet5/puppet5-release-el-7.noarch.rpm sudo rpm -ivh http://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm sudo rpm -ivh https://yum.theforeman.org/releases/1.20/el7/x86_64/foreman-release.rpm
Install Foreman stack with the forman-installer
sudo yum -y install foreman-installer sudo foreman-installer
Open necessary ports using iptables or firewalld
sudo iptables -A INPUT -p tcp --dport 53,80,3000,8140,8443 -m conntrack --ctstate NEW,ESTABLISHED -j ACCEPT sudo iptables -A OUTPUT -p tcp --sport 53,80,3000,8140,8443 -m conntrack --ctstate ESTABLISHED -j ACCEPT
or
firewall-cmd --permanent --add-port=443/tcp firewall-cmd --permanent --add-port=53/tcp firewall-cmd --permanent --add-port=80/tcp firewall-cmd --permanent --add-port=3000/tcp firewall-cmd --permanent --add-port=8140/tcp firewall-cmd --permanent --add-port=8443/tcp firewall-cmd --reload
Install chocolatey
Set-ExecutionPolicy Bypass -Scope Process -Force; iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))
Install Puppet Agent and point to Puppet Master
choco install puppet-agent -y -installArgs '"PUPPET_MASTER_SERVER=vmpuppet1.domain.local"'
Add Puppet repository
sudo rpm -Uvh https://yum.puppet.com/puppet5/puppet5-release-el-7.noarch.rpm
Install Puppet agent
sudo yum install -y puppet-agent
Make puppet agent start automatically
sudo /opt/puppetlabs/bin/puppet resource service puppet ensure=running enable=true
Add agent and server info to puppet config /etc/puppetlabs/puppet/puppet.conf
sudo su echo "[agent]" >> /etc/puppetlabs/puppet/puppet.conf echo " server = ny1sv-vmpuppet1.tpnyc.local" >> /etc/puppetlabs/puppet/puppet.conf echo " certname = $HOSTNAME" >> /etc/puppetlabs/puppet/puppet.conf echo " runinterval = 180" >> /etc/puppetlabs/puppet/puppet.conf echo " environment = production" >> /etc/puppetlabs/puppet/puppet.conf echo " listen = false" >> /etc/puppetlabs/puppet/puppet.conf echo " pluginsync = true" >> /etc/puppetlabs/puppet/puppet.conf echo " report = true" >> /etc/puppetlabs/puppet/puppet.conf
Add Puppet server hosts record
echo "'10.10.10.10 vmpuppet1.domain.local puppet" >> /etc/hosts exit
Create environments
Quick Links
Legal Stuff