<div dir="ltr">I use puppet 2.7 open source version, and typically I have my templates folder at the same level as the manifests directory within the modules I write. One thing at first glance your directory tree is listed as "templates" yet your syntax you are calling "template". Let me know how that works for you and if you're still have issues in the morning let me know, I'll check my master for further syntax since its late and I don't remember. Good luck and have fun!</div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Dec 17, 2014 at 10:30 PM, Mike Plemmons <span dir="ltr"><<a href="mailto:mikeplemmons@gmail.com" target="_blank">mikeplemmons@gmail.com</a>></span> wrote:<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">I am trying to understand the use of templates but it appears I have come across an error that has me stumped.<div><br></div><div>[root@puppet ~]# puppet agent -t</div><div>Info: Retrieving pluginfacts</div><div>Info: Retrieving plugin</div><div>Info: Loading facts</div><div>Error: Could not retrieve catalog from remote server: Error 400 on SERVER: Could not find template 'issue/issue.erb' at /etc/puppetlabs/puppet/modules/issue/manifests/init.pp:15 on node <a href="http://puppet.n1mtp.com" target="_blank">puppet.n1mtp.com</a></div><div>Warning: Not using cache on failed catalog</div><div>Error: Could not retrieve catalog; skipping run</div><div><br></div><div><br></div><div>All the documentation I see states that I am using the correct directory structure for the templates and that my use of the template in init.pp is correct. What am I missing?</div><div><br></div><div>I am using Puppet Enterprise 3.7 and performing the test on the Puppet server itself.</div><div><br></div><div><div>[root@puppet ~]# cd /etc/puppetlabs/puppet/modules</div><div>[root@puppet modules]# tree</div><div>.</div><div>└── issue</div><div> └── manifests</div><div> ├── init.pp</div><div> └── templates</div><div> └── issue.erb</div></div><div><br></div><div><div>[root@puppet manifests]# cat init.pp </div><div>class issue {</div><div> notify { 'Setting up /etc/issue': }</div><div><br></div><div> package { 'issue':</div><div> ensure => installed,</div><div> }</div><div><br></div><div> file { '/etc/issue':</div><div> path => '/etc/issue',</div><div> ensure => file,</div><div> owner => 'root',</div><div> group => 'root',</div><div> mode => '0644',</div><div> require => Package['issue'],</div><div> content => template('issue/issue.erb'),</div><div> }</div><div><br></div><div>}</div></div><div><br></div><div><div>[root@puppet manifests]# cd templates/</div><div>[root@puppet templates]# cat issue.erb <br></div><div>Puppet Test Environment</div><div>\S</div><div>Kernel \r on an \m</div><div>HN: <% @hostname %></div><div>IP: <% @ipaddress %></div></div><div><br></div><div><br></div></div>
<br>_______________________________________________<br>
colug-432 mailing list<br>
<a href="mailto:colug-432@colug.net">colug-432@colug.net</a><br>
<a href="http://lists.colug.net/mailman/listinfo/colug-432" target="_blank">http://lists.colug.net/mailman/listinfo/colug-432</a><br>
<br></blockquote></div></div>