Skip to content

Instantly share code, notes, and snippets.

@Kali-lightsaber
Forked from kgrvamsi/Puppet-101
Created March 30, 2018 19:48
Show Gist options
  • Save Kali-lightsaber/44cd8277d539c89453e8b643683fc819 to your computer and use it in GitHub Desktop.
Save Kali-lightsaber/44cd8277d539c89453e8b643683fc819 to your computer and use it in GitHub Desktop.
Puppet Installation of Server and Node
###Installtion of Master
wget https://apt.puppetlabs.com/puppetlabs-release-precise.deb
sudo dpkg -i puppetlabs-release-precise.deb
sudo apt-get update
sudo apt-get install puppetmaster-passenger -y ---- For Production based Master Setup
######### Only for Testing ################
sudo apt-get install puppetmaster -y ---- For test Master Server Setup
vim /etc/hosts
ip hostname
example--
172.27.9.56 puppetmaster
to get the hostname type this command
hostname
### Installation of Node
wget https://apt.puppetlabs.com/puppetlabs-release-precise.deb
dpkg -i puppetlabs-release-precise.deb
apt-get update
apt-get install puppet
##Checking for Puppet cert list
puppet cert list
puppet cert list --all
## Accepting the Client to the List
puppet cert sign $nodename
## Adding the agents to run on cron for every $n = mins you want to keep --- Mostly not recommended
puppet resource cron puppet-agent ensure=present user=root minute=$n command='/usr/bin/puppet agent --test'
## Master settings -- /etc/puppet/puppet.conf
[main]
dns_alt_names = puppet,puppetmaster --- dns name of the master
## Agent Settings -- /etc/puppet/puppet.conf
[agent]
server =puppetmaster
runinterval = 120 --- will run for every 2m
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment