diff options
author | Silvio Rhatto <rhatto@riseup.net> | 2019-05-13 08:55:47 -0300 |
---|---|---|
committer | Silvio Rhatto <rhatto@riseup.net> | 2019-05-13 08:55:47 -0300 |
commit | a2c7585e4236c6fe780baeb6f263c85b548ecba4 (patch) | |
tree | defb08a6083de4c93ce7af664519c7bc785bfe06 | |
parent | 4094ff54a47bf9ab3401475237d75f0cac62ddb4 (diff) | |
download | puppet-monkeysphere-a2c7585e4236c6fe780baeb6f263c85b548ecba4.tar.gz puppet-monkeysphere-a2c7585e4236c6fe780baeb6f263c85b548ecba4.tar.bz2 |
Only import key if it exists
-rw-r--r-- | manifests/import_key.pp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/manifests/import_key.pp b/manifests/import_key.pp index f3124bf..d34f00c 100644 --- a/manifests/import_key.pp +++ b/manifests/import_key.pp @@ -15,6 +15,7 @@ define monkeysphere::import_key ( exec { "monkeysphere-import-key": command => "monkeysphere-host import-key $path $key", require => [ Package["monkeysphere"], File["monkeysphere_host_conf"] ], - unless => "/usr/sbin/monkeysphere-host s | grep $key > /dev/null" + unless => "/usr/sbin/monkeysphere-host s | grep $key > /dev/null", + onlyif => "/usr/bin/test -f $path", } } |