Skip to content

Instantly share code, notes, and snippets.

@dcarley
Created May 2, 2012 16:31
Show Gist options
  • Save dcarley/2577978 to your computer and use it in GitHub Desktop.
Save dcarley/2577978 to your computer and use it in GitHub Desktop.
Replacing Puppet require() with chaining
class foo {
include ::bar
notify { $name: }
Class[$name] ~> Class["bar"]
}
class bar {
notify { $name: }
}
include ::foo
notice: foo
notice: /Stage[main]/Foo/Notify[foo]/message: defined 'message' as 'foo'
notice: bar
notice: /Stage[main]/Bar/Notify[bar]/message: defined 'message' as 'bar'
notice: Finished catalog run in 0.01 seconds
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment