]> gitweb.fluxo.info Git - puppet-monkeysphere.git/commitdiff
fix mail location on centos
authormh <mh@immerda.ch>
Mon, 25 Apr 2011 23:56:50 +0000 (01:56 +0200)
committermh <mh@immerda.ch>
Mon, 25 Apr 2011 23:56:50 +0000 (01:56 +0200)
manifests/init.pp

index 991a8dfabdebc8f54a575ad5f00c33aae082e291..c71b3b77c2138e474c3490f55d400e4ecd210985 100644 (file)
@@ -48,8 +48,12 @@ class monkeysphere {
              }
            }
     'mail': {
+            $mail_loc = $operatingsystem ? {
+               'centos' => '/bin/mail',
+               default => '/usr/bin/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":
+                    ${mail_loc} -s 'monkeysphere host pgp key for $fqdn' root < /var/lib/monkeysphere/host_keys.pub.pgp":
               unless  => "/usr/local/sbin/monkeysphere-check-key",
               user    => "root",
               require => [ Package["monkeysphere"], File["/usr/local/sbin/monkeysphere-check-key"] ],