Puppet Function: profile::mariadb::section_params::get_repl_src_dc
- Defined in:
- modules/profile/functions/mariadb/section_params/get_repl_src_dc.pp
- Function type:
- Puppet Language
Overview
1 2 3 4 5 6 7 8 9 10 11 12 13 |
# File 'modules/profile/functions/mariadb/section_params/get_repl_src_dc.pp', line 1
function profile::mariadb::section_params::get_repl_src_dc(Profile::Mariadb::Role $role) >> String {
$other_site = $site ? {
'codfw' => 'eqiad',
'eqiad' => 'codfw',
default => '(undefined)'
}
$role ? {
'slave' => $::site,
# Assumes this function will only be called if is_repl_client() returned true.
'master' => $other_site,
default => fail("Unsupported role type: ${role}"),
}
}
|