summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2011-01-20 15:10:15 -0200
committerSilvio Rhatto <rhatto@riseup.net>2011-01-20 15:10:15 -0200
commit8cfe501af0e23b6412b91183ba96cb0c3b7723bd (patch)
treedf15469f9b001707bc35b16e98227952bffc4495
parent143fb7a0ff118058c831bf9b2959b7f05a10d55d (diff)
downloadpuppet-user-8cfe501af0e23b6412b91183ba96cb0c3b7723bd.tar.gz
puppet-user-8cfe501af0e23b6412b91183ba96cb0c3b7723bd.tar.bz2
Managing GPG keys refreshing
-rw-r--r--manifests/init.pp14
1 files changed, 13 insertions, 1 deletions
diff --git a/manifests/init.pp b/manifests/init.pp
index 756e163..c381f1b 100644
--- a/manifests/init.pp
+++ b/manifests/init.pp
@@ -22,7 +22,8 @@ class user {
$sshkey_type = 'absent',
$membership = 'minimum',
$ticket = false,
- $tag = false) {
+ $tag = false,
+ $refresh_keys = false) {
if $password != 'absent' {
@@ -119,6 +120,17 @@ class user {
tag => $tag,
}
+ if $refresh_keys == true {
+ cron { "gpg-refresh-keys-${title}":
+ command => "/usr/bin/gpg --refresh-keys > /dev/null 2>&1",
+ user => $title,
+ hour => "*/1",
+ minute => "0",
+ ensure => present,
+ require => User[$title],
+ }
+ }
+
# lots of bugs preventing a good implementation for ssh keys
# http://projects.reductivelabs.com/issues/1409
# http://projects.reductivelabs.com/issues/2004