On Sat, Jan 01, 2011 at 12:53:11AM -0800, bowlby wrote: > Hi, > > I'm figuring out a way to build a ssh-gateway. For that to work I want > access to the internal ipaddresses that are used by my slaves (which > get assigned by dhcp and thus are not predictable). This way I can > change the host-file on my ssh-gateway so that hostnames point to the > right nodes. > > So I want something like: > > SSH-gateway-hostfile: > 192.168.1.12 hostname1 > 192.168.1.67 hostname2 > > Is there a way to access facts on from nodes other than the node > you're working on? >
Have a look at exported resources [1]. All your nodes that need an entry can export a resource @@host { $fqdn: ip => $ipaddress, host_aliases => $hostname, ensure => present, target => '/ssh_gateway_hostfile', tag => 'ssh-gateway', } And on your gateway you'll do Host <<| tag == 'ssh-gateway' |>> You have to enable stored configuration for that [2]. Then you run puppet agent on all your slave nodes and after that on your ssh gateway. [1] http://projects.puppetlabs.com/projects/1/wiki/Exported_Resources [2] http://projects.puppetlabs.com/projects/1/wiki/Using_Stored_Configuration -Stefan -- 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.