summaryrefslogtreecommitdiffstats
path: root/ext
diff options
context:
space:
mode:
authorLuke Kanies <luke@madstop.com>2007-10-15 19:36:32 -0500
committerLuke Kanies <luke@madstop.com>2007-10-15 19:36:32 -0500
commita815f7888b021a46332c23450795f057533d0093 (patch)
treea2f8081e47750c7782db9c3751ec4091f3f7424f /ext
parent694f98b4d9e7172cec58d407bc5aeae7861e1a06 (diff)
downloadpuppet-a815f7888b021a46332c23450795f057533d0093.tar.gz
puppet-a815f7888b021a46332c23450795f057533d0093.tar.xz
puppet-a815f7888b021a46332c23450795f057533d0093.zip
Reorganizing the file structure for indirection terminus types.
Previously, for example, the configuration terminus that was a subclass of 'code' would have been stored at lib/puppet/indirector/code/configuration and would have had to have been named 'configuration'. Now, the subclass can be named however the author prefers, and it must be stored at lib/puppet/indirector/configuration/<name>.rb, where <name> is the name you've chosen for the terminus type. The name only matters insomuch as it is used to load the file from disk and find the appropriate class when asked. The additional restriction is that the class constant for the terminus type must have its name as the last word, and the indirection must be the second to last word. Thus, in our example, we can choose any class constant that ends with Configuration::Code; given that there's only one Configuration class at this point, it makes the most sense to define the class as Puppet::Node::Configuration::Code. This is somewhat awkward, because of the class's location on disk, but the only other real option is to autogenerate a Puppet::Indirector::Configuration class constant, which is, I think, uglier.
Diffstat (limited to 'ext')
-rwxr-xr-xext/module_puppet2
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/module_puppet b/ext/module_puppet
index 36efb4f0e..08fc9beb2 100755
--- a/ext/module_puppet
+++ b/ext/module_puppet
@@ -158,7 +158,7 @@ unless ENV.include?("CFALLCLASSES")
end
# Collect our facts.
-Puppet::Node::Facts.terminus_class = :code
+Puppet::Node::Facts.terminus_class = :facter
facts = Puppet::Node::Facts.find("me")
facts.name = facts.values["hostname"]