summaryrefslogtreecommitdiff
path: root/manifests/agent/config.pp
diff options
context:
space:
mode:
authorMatt Taggart <taggart@riseup.net>2014-04-22 00:17:34 -0700
committerMatt Taggart <taggart@riseup.net>2014-04-22 00:17:34 -0700
commit25b9b5f7cd2d64f464fb198d90cc757a1bff1c81 (patch)
treeb45362c40c5afd1dc18e6d8edfb7a6a30eff6b94 /manifests/agent/config.pp
parent88d466e3aca349b3f129dd8e8967b90002a2584b (diff)
replace homedir with more specific keydir, authdir, and authfile in order to allow overriding each. modify ::agent, ::agent::config, and ::agent::generate_sshkey to allow changing at each level, with reasonable defaults
Diffstat (limited to 'manifests/agent/config.pp')
-rw-r--r--manifests/agent/config.pp21
1 files changed, 17 insertions, 4 deletions
diff --git a/manifests/agent/config.pp b/manifests/agent/config.pp
index 256af8f..40b9ff5 100644
--- a/manifests/agent/config.pp
+++ b/manifests/agent/config.pp
@@ -1,8 +1,10 @@
class check_mk::agent::config (
- $ip_whitelist = '',
+ $ip_whitelist = '',
$port,
$server_dir,
- $homedir,
+ $keydir,
+ $authdir,
+ $authfile = undef,
$use_cache,
$user,
$method = 'xinetd',
@@ -34,8 +36,19 @@ class check_mk::agent::config (
}
'ssh' : {
if $generate_sshkey {
- check_mk::agent::generate_sshkey { 'check_mk_key':
- homedir => $homedir
+ if $authfile {
+ # if authfile is overridden, pass it through
+ check_mk::agent::generate_sshkey { 'check_mk_key':
+ keydir => $keydir,
+ authdir => $authdir,
+ authfile => $authfile
+ }
+ } else {
+ # otherwise don't
+ check_mk::agent::generate_sshkey { 'check_mk_key':
+ keydir => $keydir,
+ authdir => $authdir
+ }
}
}
}