summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--templates/reprepro-export-key.sh.erb2
1 files changed, 2 insertions, 0 deletions
diff --git a/templates/reprepro-export-key.sh.erb b/templates/reprepro-export-key.sh.erb
index 7b3c2ed..e629f9d 100644
--- a/templates/reprepro-export-key.sh.erb
+++ b/templates/reprepro-export-key.sh.erb
@@ -3,6 +3,8 @@
# This file is managed by Puppet. Do not edit, any changes will be overwritten!
#
+set -e
+
KEY="$(gpg --homedir '<%= @basedir %>/.gnupg' --with-colon --list-secret-keys | cut -d : -f 5 | head -n 1)"
if [ -n "$KEY" ]; then