Hi, I''m gradually moving my site''s config over to Puppet (still in the testing phases at the moment!). Is there any way of getting/referring to a host''s IP address? I want to set up iptables via Puppet, & can use a template but need to get the IP address into the template somehow. I''m getting my node definitions (& thus classes) from LDAP. I know that I could define a separate class for each node, but I''m not particularly keen to do that. thanks, Juliet -- +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + Ms Juliet Kemp + + Computer Manager star@imperial.ac.uk + + Astrophysics Group + + Imperial College Tel: +44 (0)20759 47538 + + London. SW7 2AZ Fax: +44 (0)20759 47541 + +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Juliet Kemp wrote:> I''m gradually moving my site''s config over to Puppet (still in the > testing phases at the moment!). > > Is there any way of getting/referring to a host''s IP address? I want to > set up iptables via Puppet, & can use a template but need to get the > IP address into the template somehow. > > I''m getting my node definitions (& thus classes) from LDAP. I know that > I could define a separate class for each node, but I''m not particularly > keen to do that. > >Facter provides the ipaddress "fact". Type facter to see all the facts that puppet knows about. Vladimir
Vladimir wrote:> Juliet Kemp wrote: >> Is there any way of getting/referring to a host''s IP address? I want to >> set up iptables via Puppet, & can use a template but need to get the >> IP address into the template somehow. > > Facter provides the ipaddress "fact". Type facter to see all the facts > that puppet knows about.Great, thank you! All works well now. Juliet -- +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + Ms Juliet Kemp + + Computer Manager star@imperial.ac.uk + + Astrophysics Group + + Imperial College Tel: +44 (0)20759 47538 + + London. SW7 2AZ Fax: +44 (0)20759 47541 + +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++