#171: Expand Puppet Configuration Management System - Rmhibbert/oe2-group-c GitHub Wiki

link to the ticket: https://rt.dataraster.com/Ticket/Display.html?id=175

Add the Puppet repository

Description: Download and install the Puppet 7 repository package on the database server. This step ensures that Puppet can be installed and updated using apt.

Command:

  • wget https://apt.puppet.com/puppet7-release-jammy.deb
  • sudo dpkg -i puppet7-release-jammy.deb
  • sudo apt update

Install the Puppet agent package

Description: Install the Puppet agent package, which allows the server to communicate with the Puppet master.

Command: sudo apt install puppet-agent -y


Configure the Puppet agent

Description: Modify the Puppet agent configuration file to specify the Puppet server and certificate name.

Command: sudo nano /etc/puppetlabs/puppet/puppet.conf Added the following line under main

server = mgmt-c

certname = backup-c.oe2.org.nz


Description: Start and enable the Puppet agent:

Command:

sudo systemctl start puppet

sudo systemctl enable puppet


Description: Verify the Puppet agent is running:

Command:

sudo systemctl status puppet


Description: Connect your agent to the puppet server manually with the following command:

Command:

sudo puppet agent --server=mgmt-c --no-daemonize --verbose --onetime


Description: If the puppet command is not recognized the following command is required

Command:

sudo ln -s /opt/puppetlabs/server/bin/puppetserver /usr/bin/puppetserver


Description: If there is any issues with certificate run these commands on the agent Command:

sudo puppet resource service puppet ensure=stopped

sudo rm -r /etc/puppetlabs/puppet/ssl

sudo puppet resource service puppet ensure=running

sudo systemctl restart puppet

sudo systemctl start puppet

sudo systemctl enable puppet


Description: Now the agent is waiting for the puppet to sign Command:


Description: The puppet has now signed and agent is linked up Command: