I'd like to get an idea on the recommended practice in scenarios where you
have a cluster of nodes setup in master/slave(s) mode which needs specific
configuration files.
The following setup includes writing a custom fact to retrieve a value from
the hostname and then comparing it against a pre-determined host value set
in hiera. i.e:
# list of hosts
host01,host02,host03
# custom fact
rank: 01,02,03
# set in hiera
master:01
if $::rank == $master {
class { 'solr::conf::master' : }
} else{
class { 'solr::conf::slave' :
master_fqdn => $master_fqdn,
}
}
I understand that if the master goes down a manual hiera update is required
to set the new hiera master value.
i'm keen to know if there other (better) ways of handing this?
--
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 [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/puppet-users/2aef8e8e-117f-45bb-ba4f-4b813b96bd07%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.