Dan
2013-02-20 17:10:50 UTC
Hi,
I've defined a hash like so in my nodes.pp:
net::addr { "eth5":
rt => {
rt1 => {
address => '192.168.10.0',
netmask => '255.255.255.0',
gateway => '192.5.28.19',
src => '192.5.28.21'
},
}
What I can't get to access is the title of the hash in my templates, so I
want to print out the title of the hash i.e. "eth5", how can I do that?
Also I have a variable called $int in my define class in the file for my
module (/etc/puppet/modules/net/manifests/addr.pp), how can I access that
using the scope.lookupvar function from this template in the same module?
Thanks Dan
I've defined a hash like so in my nodes.pp:
net::addr { "eth5":
rt => {
rt1 => {
address => '192.168.10.0',
netmask => '255.255.255.0',
gateway => '192.5.28.19',
src => '192.5.28.21'
},
}
What I can't get to access is the title of the hash in my templates, so I
want to print out the title of the hash i.e. "eth5", how can I do that?
Also I have a variable called $int in my define class in the file for my
module (/etc/puppet/modules/net/manifests/addr.pp), how can I access that
using the scope.lookupvar function from this template in the same module?
Thanks Dan
--
You received this message because you are subscribed to the Google Groups "Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+***@googlegroups.com.
To post to this group, send email to puppet-***@googlegroups.com.
Visit this group at http://groups.google.com/group/puppet-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
You received this message because you are subscribed to the Google Groups "Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+***@googlegroups.com.
To post to this group, send email to puppet-***@googlegroups.com.
Visit this group at http://groups.google.com/group/puppet-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.