On Mon, Feb 13, 2012 at 9:36 AM, Jeffrey Watts <[email protected]>wrote:
> Yes, thanks. My only concern though is that catalogs will fail to compile
> if that particular module that it's located in isn't included in that node
> definition. I worry that any successors will not be able to easily figure
> out what I've done.
>
>
And I don't think I've cleared this up for you - you DON'T NEED TO INCLUDE
the class in a node declaration for a node to have that module's custom
facts loaded and available to your node. For example, if this fact lived
in the mysql module, you DO NOT NEED to have 'include mysql' in the node
declaration for the node to have access to the custom fact. Custom facts
get synced down to the clients via Pluginsync, and ALL custom facts that
are in ANY modules in your $modulepath will automatically get synced down
to ALL Puppet nodes BEFORE Puppet starts running REGARDLESS of whether that
module's classes are declared in a node declaration.
BTW, don't misinterpret the emphasis for yelling - just trying to emphasize
specific points that I might have glossed-over previously :)
> Could I create a module named "global" and have it simply be where things
> like that live? What's the minimum I'd need to have in it? An init.pp
> with simply "class global { }"? Are there other, better ways?
>
> Thanks again,
> Jeffrey.
>
>
> On Mon, Feb 13, 2012 at 11:29 AM, Gary Larizza <[email protected]>wrote:
>>
>>
>> Hi Jeffrey,
>>
>> You're correct about the placement of the file, however you don't need to
>> include it in EVERY module you use. That fact only needs to be in ONE of
>> your modules for every node to utilize it as a Facter fact (currently, ANY
>> Facter facts that are in your $modulepatch get loaded by ALL of your nodes).
>>
>> So repeating this code is very redundant. Does this makes sense?
>>
>> --
> You received this message because you are subscribed to the Google Groups
> "Puppet Users" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected].
> For more options, visit this group at
> http://groups.google.com/group/puppet-users?hl=en.
>
--
Gary Larizza
Professional Services Engineer
Puppet Labs
--
You received this message because you are subscribed to the Google Groups
"Puppet Users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/puppet-users?hl=en.