You should really think about this more closely. Imagine you had the
*rand* function that gives you an integer from 1..3 now if you define 

    $ipaddress = rand()

in your manifest you will now generate a new ipaddress on each puppet
agent run.

If you want that we can tell you how to do it(I even think it is in the
example at puppet custom function)

P.S. I had to learn this the hard way by trying to balance a cassandra
cluster with proper initial_tokens.

Best, Nikola

On Tue, Dec 04, 2012 at 08:44:03AM -0800, Matthias Kellermann wrote:
> Hi there,
> 
> I have a network service with three IP addresses. For my client config file 
> I want to choose a random IP addresses of the three available addresses 
> (round robin via DNS won't work..).
> 
> Is there a way to use a random IP from an array in a puppet template?
> 
> Thanks and best regards,
> Matthias
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Puppet Users" group.
> To view this discussion on the web visit 
> https://groups.google.com/d/msg/puppet-users/-/8PrcZfi0VMkJ.
> To post to this group, send email to puppet-users@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.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To post to this group, send email to puppet-users@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