In this guide, you'll create a new node group, then apply
a named chunk of Puppet code --- better
known as a class --- to the node group. You'll apply the apache
class to your agent node, which will allow you to launch
the default Apache virtual host on your
agent node.
Complete a basic classification workflow
Classifying nodes associates classes with nodes so that the code they contain can be used by that node.
These instructions assume
you've installed a monolithic PE
deployment, and have installed at least one *nix agent node and the puppetlabs-apache
module.
Every module contains
one or more classes -- a named chunk of Puppet code. Classes are the primary means by which
Puppet Enterprise configures nodes. The
puppetlabs-apache
module you
installed in the module installation getting started guide contains a class called
apache
. In this section, you
apply the apache
class to your
agent node
Create a node group
Node groups enable you to assign classes to more than one node at a time.
You could assign classes to individual nodes one at a time, but chances are, each of your classes needs to be applied to more than one node. By creating a node group, you can apply a class to many nodes at once.
Step 2: Add nodes to the node group
Add nodes to a node group to manage them more efficiently.
To add nodes to a node group, create rules that define which nodes should be included in the group.
-
Click the
apache_example
group. - From the Rules tab, in the Certname area, in the Node name field, enter the name of your PE agent node.
- Click Pin node.
- Commit changes.
- Repeat these steps for any other nodes you want to add to the node group.
Step 3: Add the apache class to the node group
After you create a node group, add classes to give the matching nodes purpose.
Step 4: Edit class parameters in the console
You can use the console to modify the values of a class's parameters without editing the module code directly.
Puppet Enterprise is now managing the default Apache vhost on your agent node. Next, you'll learn how to manage users with PE, and how to set permissions for each user or group of users.