I've set up a puppet environment which uses mercurial to store the configuration and manifests. Now I'm trying to build an environment to be able to test changes before I commit them to the repository, and they propagate to all our 400 servers - but I encountered a problem.
You can use a separate configuration directory with the --confdir
option for both puppetd and puppetmasterd,
and run everything on localhost,
but the problem is the source parameter
file { "/etc/profile":
owner => root,
group => root,
mode => 644,
source => "puppet://server/base/profile"
}
The above source parameter contains the hostname,
so when I want to test it on my local mercurial repository,
it still connects to the server instead of localhost when it fetches the files.
Luckily there is a solution!
If you leave out the server part,
puppetd will insert the name of the server it is connecting to.





