aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormh <mh@d66ca3ae-40d7-4aa7-90d4-87d79ca94279>2008-06-17 07:57:46 +0000
committermh <mh@d66ca3ae-40d7-4aa7-90d4-87d79ca94279>2008-06-17 07:57:46 +0000
commit8bc696b174ea0999aa46215f53171dac7e8e9720 (patch)
tree01b5f887c0b45a32f8d94989c1ef2200b793ff1c
parentece3afde12bea114ea36be3186c069ed8403317b (diff)
downloadpuppet-sshd-8bc696b174ea0999aa46215f53171dac7e8e9720.tar.gz
puppet-sshd-8bc696b174ea0999aa46215f53171dac7e8e9720.tar.bz2
readded a source
git-svn-id: https://svn/ipuppet/trunk/modules/sshd@1628 d66ca3ae-40d7-4aa7-90d4-87d79ca94279
-rw-r--r--manifests/init.pp8
1 files changed, 7 insertions, 1 deletions
diff --git a/manifests/init.pp b/manifests/init.pp
index 4539dd6..aa0ebfc 100644
--- a/manifests/init.pp
+++ b/manifests/init.pp
@@ -141,6 +141,7 @@ class sshd::openbsd inherits sshd::base {
### defines
define sshd::deploy_auth_key(
+ $source = 'present',
$user = 'root',
$target_dir = '/root/.ssh/',
$group = 0 ) {
@@ -157,12 +158,17 @@ define sshd::deploy_auth_key(
mode => 700,
}
+ case $source {
+ 'present': { $keysource = $name }
+ default: { $keysource = $source }
+ }
+
file {"authorized_keys_${user}":
path => "$real_target/authorized_keys",
owner => $user,
group => $group,
mode => 600,
- source => [ "puppet://$server/files/sshd/authorized_keys/${name}",
+ source => [ "puppet://$server/files/sshd/authorized_keys/${keysource}",
"puppet://$server/files/sshd/authorized_keys/${fqdn}",
"puppet://$server/files/sshd/authorized_keys/default",
"puppet://$server/sshd/authorized_keys/${name}",