diff options
author | Silvio Rhatto <rhatto@riseup.net> | 2010-09-25 22:27:00 -0300 |
---|---|---|
committer | Silvio Rhatto <rhatto@riseup.net> | 2010-09-25 22:27:00 -0300 |
commit | 139b3d373e3f021caa6f4226ac880b01fffb4f58 (patch) | |
tree | c15ebd44677065c8e34bd011523150b2246dedbf | |
parent | 28ee8f4e7d762bdc5eb061f2bbfad35a9dff7037 (diff) | |
download | puppet-monkeysphere-139b3d373e3f021caa6f4226ac880b01fffb4f58.tar.gz puppet-monkeysphere-139b3d373e3f021caa6f4226ac880b01fffb4f58.tar.bz2 |
Support for sending pubkey by mail
-rw-r--r-- | manifests/init.pp | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/manifests/init.pp b/manifests/init.pp index a4e60ad..de91cc8 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -1,7 +1,7 @@ # This module is distributed under the GNU Affero General Public License: # # Monkeysphere module for puppet -# Copyright (C) 2009 Sarava Group +# Copyright (C) 2009-2010 Sarava Group # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as @@ -39,6 +39,14 @@ class monkeysphere { require => Package["monkeysphere"], } } + 'mail': { + exec { "/usr/sbin/monkeysphere-host import-key /etc/ssh/ssh_host_rsa_key $key && \ + /usr/bin/mail -s 'monkeysphere host pgp key for $fqdn' root < /var/lib/monkeysphere/host_keys.pub.pgp": + unless => "/usr/bin/gpg --homedir /var/lib/monkeysphere/host --list-keys '=$key' &> /dev/null", + user => "root", + require => Package["monkeysphere"], + } + } default: { exec { "/usr/sbin/monkeysphere-host import-key /etc/ssh/ssh_host_rsa_key $key && \ /usr/sbin/monkeysphere-host publish-key": |