Skip to content

Commit d2d83e5

Browse files
author
Gavin Williams
committed
Fix private variable usage for '_plugindir'
1 parent 67a0720 commit d2d83e5

File tree

4 files changed

+8
-8
lines changed

4 files changed

+8
-8
lines changed

manifests/config.pp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@
4848
group => $elasticsearch::elasticsearch_group,
4949
owner => $elasticsearch::elasticsearch_user,
5050
mode => '0750';
51-
$elasticsearch::_plugindir:
51+
$elasticsearch::real_plugindir:
5252
ensure => 'directory',
5353
group => $elasticsearch::elasticsearch_group,
5454
owner => $elasticsearch::elasticsearch_user,
@@ -238,7 +238,7 @@
238238
}
239239

240240
} elsif ( $elasticsearch::ensure == 'absent' ) {
241-
file { $elasticsearch::_plugindir:
241+
file { $elasticsearch::real_plugindir:
242242
ensure => 'absent',
243243
force => true,
244244
backup => false,

manifests/init.pp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -449,9 +449,9 @@
449449

450450
# Set the plugin path variable for use later in the module.
451451
if $plugindir == undef {
452-
$_plugindir = "${homedir}/plugins"
452+
$real_plugindir = "${homedir}/plugins"
453453
} else {
454-
$_plugindir = $plugindir
454+
$real_plugindir = $plugindir
455455
}
456456

457457
# Should we restart Elasticsearch on config change?

manifests/package.pp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@
181181

182182
exec { 'remove_plugin_dir':
183183
refreshonly => true,
184-
command => "rm -rf ${elasticsearch::_plugindir}",
184+
command => "rm -rf ${elasticsearch::real_plugindir}",
185185
}
186186

187187

manifests/plugin.pp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@
7878
}
7979
'absent': {
8080
$_file_ensure = $ensure
81-
$_file_before = File[$elasticsearch::_plugindir]
81+
$_file_before = File[$elasticsearch::real_plugindir]
8282
}
8383
default: { }
8484
}
@@ -127,10 +127,10 @@
127127
source => $file_source,
128128
url => $url,
129129
proxy => $_proxy,
130-
plugin_dir => $elasticsearch::_plugindir,
130+
plugin_dir => $elasticsearch::real_plugindir,
131131
plugin_path => $module_dir,
132132
}
133-
-> file { "${elasticsearch::_plugindir}/${_module_dir}":
133+
-> file { "${elasticsearch::real_plugindir}/${_module_dir}":
134134
ensure => $_file_ensure,
135135
mode => 'o+Xr',
136136
recurse => true,

0 commit comments

Comments
 (0)