Install the iis module

Modules are self-contained, shareable bundles of code and data. Each module manages a specific task in your infrastructure, such as installing and configuring a piece of software. With Puppet Enterprise (PE), a lot of your infrastructure is supported by modules, so it is important to learn how to install, build, and use them. To practice working with modules, try installing the puppetlabs/iis module, which automates installing, configuring, and managing IIS services.

Before you begin
Install PE and at least one Windows agent node before installing the iis module.
Tip: You can write your own modules or download pre-built modules from the Forge. While you can use any module on the Forge, PE customers can take advantage of supported modules. These modules are designed to facilitate common services, and they are tested and maintained by Puppet.
  1. Go to the IIS module page on the Forge.
  2. Select r10k or Code Manager as the Installation Method, and follow the instructions to add the module declaration to your Puppetfile.

    By default, Code Manager installs the latest version and disables automatic updates; however, you can specify options to install a different version or keep the module current with the latest version. To automatically update the module when a new version is released, specify :latest (such as mod 'puppetlabs/iis', :latest). To install a specific version of the module and prevent automatic updates, specify the version number as a string (such as mod 'puppetlabs/iis, '7.0.0').

  3. Make sure your Puppetfile includes module declarations for the puppetlabs/pwshlib module, which is a dependency of the iis module. Dependencies for each module are listed on the Dependencies tab on the module’s Forge page, and you can specify the desired version in the same way you did for the primary module.
    For example, this code installs version 7.0.0 of the iis module, installs the module's dependency, and prevents automatic updates (due to specified version numbers):
    mod 'puppetlabs/iis, '7.0.0'
    mod ‘puppetlabs/pwshlib’, ‘0.4.0’
  4. SSH into your primary server and deploy code running the puppet-code deploy --all command.
Results
You installed the iis module. Installing a module makes it available in PE so you can use it to manage nodes.
What to do next
To continue managing IIS configuration on Windows targets, Set up IIS node groups.