Set up your prerequisites
If you're new to using roles and profiles, do some additional setup before writing any new code.
- Create two modules: one named
role, and one namedprofile.If you deploy your code with Code Manager or r10k, put these two modules in your control repository instead of declaring them in your Puppetfile, because Code Manager and r10k reserve the
modulesdirectory for their own use.- Make a new directory in the repo named
site. - Edit the
environment.conffile to addsiteto themodulepath. (For example:modulepath = site:modules:$basemodulepath). - Put the
roleandprofilemodules in thesitedirectory.
- Make a new directory in the repo named
- Make sure Hiera or Puppet lookup is set up and working, with a hierarchy that works well for you.






