if a template exists in modules/foo/templates/bar.erb

you refer to it as

template("foo/bar.erb")

in manifests.




On Tue, Mar 23, 2010 at 10:12 AM, Allan Marcus <al...@lanl.gov> wrote:
> I am confused about the template dir in the module/{modulename}/ dir
>
> Does the autoloader look in /env1/modules/{modulename}/templates/ 
> automatically, or do I need to refer to the template by its full path?
>
> http://projects.reductivelabs.com/projects/puppet/wiki/Puppet_Templating
> states that a tempaltedir needs to be defined for the environment, not the 
> module.
>
> I'm confused.
>
> ---
> Thanks,
>
> Allan Marcus
> 505-667-5666
>
>
>
> On Mar 22, 2010, at 5:24 PM, Allan Marcus wrote:
>
>> hello,
>>
>> Is this directory structure for modules still recommended, or is there a 
>> better way?
>>
>> http://projects.reductivelabs.com/projects/puppet/wiki/Module_Organisation
>>
>> We are thinking of having a directory for each environment, then broken down 
>> as recommended here:
>>
>> http://projects.reductivelabs.com/projects/puppet/wiki/Puppet_Best_Practice
>>
>> So in practice, it might look like
>>
>> Environments
>> /env1
>> /env1/manifests/site.pp
>> /env1/manifests/templates.pp
>> /env1/manifests/nodes.pp
>> /env1/modules/{modulename}/files/
>> /env1/modules/{modulename}/manifests/init.pp
>> /env1/modules/{modulename}/manifests/class1.pp
>> /env1/modules/{modulename}/manifests/definition1.pp
>> /env1/modules/{modulename}/manifests/class2.pp
>> /env1/modules/{modulename}/plugins/
>> /env1/modules/{modulename}/templates/
>>
>> /env2
>> ...
>> /env3
>> ...
>>
>> Does this look right?
>>
>> ---
>> Thanks,
>>
>> Allan Marcus
>> 505-667-5666
>>
>>
>>
>
>



-- 
nigel

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To post to this group, send email to puppet-us...@googlegroups.com.
To unsubscribe from this group, send email to 
puppet-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en.

Reply via email to