Skip to content

Commit

Permalink
Replace all occurences of illegal chars in the name var
Browse files Browse the repository at this point in the history
  • Loading branch information
Sergei Gerasenko authored and bastelfreak committed Jan 26, 2024
1 parent df51ce8 commit e7f8369
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion manifests/lvs/real_server.pp
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
Stdlib::Port $port,
Keepalived::Options $options = {},
) {
$_name = regsubst($name, '[:\/\n]', '')
$_name = regsubst($name, '[:\/\n]', '', 'G')

concat::fragment { "keepalived.conf_lvs_real_server_${_name}":
target => "${keepalived::config_dir}/keepalived.conf",
Expand Down
2 changes: 1 addition & 1 deletion manifests/lvs/virtual_server.pp
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@
Hash $real_server_options = {},
Optional[Stdlib::Fqdn] $virtualhost = undef,
) {
$_name = regsubst($name, '[:\/\n]', '')
$_name = regsubst($name, '[:\/\n]', '', 'G')

unless $fwmark {
assert_type(Stdlib::Port, $port)
Expand Down
2 changes: 1 addition & 1 deletion manifests/vrrp/script.pp
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
$no_weight = false,
$init_fail = false,
) {
$_name = regsubst($name, '[:\/\n]', '')
$_name = regsubst($name, '[:\/\n]', '', 'G')

if ! $weight {
$weight_real = 2
Expand Down
2 changes: 1 addition & 1 deletion manifests/vrrp/sync_group.pp
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
Boolean $global_tracking = false,
Optional[Variant[String, Array[String]]] $track_interface = undef,
) {
$_name = regsubst($name, '[:\/\n]', '')
$_name = regsubst($name, '[:\/\n]', '', 'G')

concat::fragment { "keepalived.conf_vrrp_sync_group_${_name}":
target => "${keepalived::config_dir}/keepalived.conf",
Expand Down

0 comments on commit e7f8369

Please sign in to comment.