On our puppet box ( under the puppet/modules folder ) , I have added a module for installing a package. I then added the classes needed for the resources into the init.pp ( and other derived class files ) into the manifests folder. I configured these classes and the corresponding nodes associated with them in the puppet dashboard.

When I run puppet-agent with the environment flag , I see that puppet does not run my module. It is running couple of other modules defined similarly on the box alongside my module , but not my module.

What configuration is needed so puppet-agent picks up a module and runs the manifests it defines ? For simplicity , I want to do this on one box first.

2 Answers 2


So, a module is a great way to create a contained re-usable class. However, to deploy a module, it has to be called/defined, which is not done by default.

You can do this one of two ways -- if it's a one time sort of thing, you can simple do a; puppet apply -e 'module' on the agent and that should apply the module (or give you an error ;)!)

However, if it's something you wanted to permanently alter... I'd do something like this.

Create file called nodes.pp @ /etc/puppet/manifests In nodes.pp;

node 'test.domain.com' { include modulename }

Then in site.pp @ /etc/puppet/manifests, you just have to make sure at the top there is;

import 'nodes.pp'

Then you can run like a puppet agent -t and you'll see it attempt to get the module.


You should include module in your init.pp or dependent modules so that it will be visible during dependency check.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.