Hey all, Ok, sorry if I didn't get to all of your suggestions. But I did elect to try this one:
server-id=<%= @hostname.match(/db([0-9]+)/); $1 %> Which I modified slightly to: server-id=<%= @hostname.match(/db([0-4]+)/); $1 %> Because I only run 4 mysql servers atm. And BOOM! That does it exactly right!! On db1 I get: server-id=1 on db2: server-id=2 and so on and so on. Works perfectly. Shout out to Christopher Wood for his "untested" regex expression. Which when tested worked perfectly! Thanks, Tim On Tue, Sep 15, 2015 at 4:18 PM, Ramin K <ramin-l...@badapple.net> wrote: > On 9/15/15 1:15 PM, Ramin K wrote: > > server_id = <% require 'ipaddr'%><%= IPAddr.new(@ipaddress).to_i %> >> server_id = fqdn_rand(2147483647). >> > > that last should have been <%= scope.function_fqdn_rand(2147483647) %> > assuming it was also in a template. > > Ramin > > -- > 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+unsubscr...@googlegroups.com. > To view this discussion on the web visit > https://groups.google.com/d/msgid/puppet-users/55F87CFB.5020103%40badapple.net > . > > For more options, visit https://groups.google.com/d/optout. > -- GPG me!! gpg --keyserver pool.sks-keyservers.net --recv-keys F186197B -- 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+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CAOZy0e%3DFDmn-NwEe9mJfu3YBbdcgn30-upTc-3LJWFPAiCczaQ%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.