Most people that work with puppet use a VCS : subversion, git, CVS, mercurial… Pick yours. My company uses subversion and each cmmit to the repository needs to be pulled by the master. Since I have two masters, I also want them to be synchronized. Once again it’s mcollective that comes to the rescue. I wrote a very simple agent (a 5 minutes work, to be improved) that can update a specified path. Grab it here. Once it is deployed you can use a post commit hook that calls it.
Example of mine :
#!/usr/local/bin/ruby require 'mcollective' include MCollective::RPC mc = rpcclient("svnagent") mc.progress = false mc.class_filter "puppet::master" mc.update(:path => "/etc/puppet")
The agent will only be called on machines being puppet masters by using the class filter.

