Puppet Enterprise supports Cisco NX-OS release 7.0 and higher as a platform for running Puppet agents on their network switches. Supported Cisco switches include:
These instructions assume you’ve already installed Puppet Enterprise and have a compatible Cisco Nexus switch running the minimum required version of NX-OS. Installing the Cisco agent requires that you install the puppet-ciscopuppet module, which contains the types and providers needed to configure your Cisco Nexus switches.
On your Puppet master, run, puppet module install puppetlabs-ciscopuppet
.
NX-OS supports two possible environments for running third-party software: bash shell or guest shell. Choose one environment for running Puppet agents and follow the appropriate steps below. (Note that you can run Puppet from either environment but not both at the same time.)
Note: To install the Puppet agent, we recommend 400 MB of free disk space on bootflash.
Follow the steps in this section only if you plan to run the Puppet agent from the bash environment.
Tip: The bash environment is disabled by default. If you haven’t enabled it already, you should consider using the “guest shell” environment instead.
These instructions assume you have networking and DNS configured for the bash environment. Detailed instructions on doing this can be found in the section “Puppet agent environment: bash-shell” from README-AGENT-INSTALL.md in the ciscopuppet module.
To install the Puppet agent with bash:
Start a root bash shell with networking enabled. From the command line of your network switch, run the following commands:
run bash
sudo ip netns exec management bash
Install the Puppet Collections PC1 repository package for cisco_wrlinux:
bash-4.2# yum install http://yum.puppetlabs.com/puppetlabs-release-pc1-cisco-wrlinux-5.noarch.rpm
Install the Puppet agent:
yum install puppet-agent
The Puppet agent is now installed under /opt/puppetlabs
. Add the bin
and lib
paths to your login shell’s PATH
:
export PATH=$PATH:/opt/puppetlabs/puppet/bin:/opt/puppetlabs/puppet/lib
Follow the steps in this section only if you plan to run the Puppet agent from the “guest shell” environment.
Start a root guest shell, and install the Puppet Collections PC1 repository package for EL-7:
sudo su -
yum install http://yum.puppetlabs.com/puppetlabs-release-pc1-el-7.noarch.rpm
Install the Puppet agent:
yum install puppet-agent
The Puppet agent is now installed under /opt/puppetlabs
. Add the bin
and lib
paths to your login shell’s PATH
:
export PATH=$PATH:/opt/puppetlabs/puppet/bin:/opt/puppetlabs/puppet/lib
The commands to uninstall the Puppet agent are the same for both Bash and “guest shell” environments.
Remove the Puppet agent:
sudo su -
yum remove puppet-agent
Remove the Puppet Collections PC1 repository package package:
yum remove puppetlabs-release-pc1
Refer to the puppet-ciscopuppet module for more information about using the module on your network switch.