/[adm]/puppet/modules/gnupg/manifests/init.pp
ViewVC logotype

Contents of /puppet/modules/gnupg/manifests/init.pp

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2624 - (show annotations) (download)
Mon Mar 19 17:11:37 2012 UTC (12 years, 1 month ago) by misc
File size: 1258 byte(s)
split gnupg::client in a separate file, and clean it
1 class gnupg {
2 # debian recommend SHA2, with 4096
3 # http://wiki.debian.org/Keysigning
4 # as they are heavy users of gpg, I will tend
5 # to follow them
6 # however, for testing purpose, 4096 is too strong,
7 # this empty the entropy of my vm
8 define keys( $email,
9 $key_name,
10 $key_type = 'RSA',
11 $key_length = '4096',
12 $expire_date = '400d',
13 $login = 'signbot',
14 $batchdir = '/var/lib/signbot/batches',
15 $keydir = '/var/lib/signbot/keys'
16 ) {
17
18 include gnupg::client
19 file { "$name.batch":
20 ensure => present,
21 path => "$batchdir/$name.batch",
22 content => template("gnupg/batch")
23 }
24
25 file { "$keydir":
26 ensure => directory,
27 owner => $login,
28 mode => 700,
29 }
30
31 file { "$batchdir":
32 ensure => directory,
33 owner => $login,
34 }
35
36 exec { "/usr/local/bin/create_gnupg_keys.sh $batchdir/$name.batch $keydir $batchdir/$name.done":
37 user => $login,
38 creates => "$batchdir/$name.done",
39 require => [File["$keydir"], File["$batchdir/$name.batch"], Package["rng-utils"]],
40 }
41 }
42 }

  ViewVC Help
Powered by ViewVC 1.1.30