summaryrefslogtreecommitdiffstats
path: root/lib/puppet/faces/configurer.rb
blob: d40987697f4310767485418a9c14d8c858f07a2c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
require 'puppet/faces'

Puppet::Faces.define(:configurer, '0.0.1') do
  action(:synchronize) do
    when_invoked do |certname, options|
      facts = Puppet::Faces[:facts, '0.0.1'].find(certname)
      catalog = Puppet::Faces[:catalog, '0.0.1'].download(certname, facts)
      report = Puppet::Faces[:catalog, '0.0.1'].apply(catalog)
      report
    end
  end
end