Here is a quick intro for how to use strings for those not very familiar with puppet and the command line.
Do this once to get strings set up:
- Installing strings
$ puppet module install puppetlabs-strings
- Install the yard gem
$ gem install yard
Strings looks at your source code, parses it and looks at comments and then makes a website out of them. It puts the website in the doc/
directory.
- Find where your modules live:
$ puppet config print modulepath
It might output something like /Users/iankronquist/.puppetlabs/etc/code/modules
.
Copy that path, that's where all your puppet modules live.
- Download a new module from the forge:
$ puppet module install puppetlabs-apache
- Running strings on a module
First, go where your modules are stored on the module path (the path we copied earlier)
$ cd /Users/iankronquist/.puppetlabs/etc/code/modules
Next go to the module you want to document:
$ cd apache
- Run strings:
$ puppet strings
- Now look at the documentation:
$ open doc/index.html