]> git.apps.os.sepia.ceph.com Git - autobuild-ceph.git/commitdiff
rpm-autosign.exp: New utility to help sign rpms.
authorGary Lowell <glowell@inktank.com>
Fri, 8 Mar 2013 05:03:18 +0000 (21:03 -0800)
committerGary Lowell <glowell@inktank.com>
Fri, 8 Mar 2013 05:03:18 +0000 (21:03 -0800)
The rpm commend insists on prompting for a passphrase when signing rpms even
for passphraselees keys.  This behaviour causes problems for automated build
scripts.  The rpm-autosign.exp scripts is a small expect wrapper for rpm that
that sends empty passphrase in reposne to the prompt.

Signed-off-by: Gary Lowell <gary.lowell@inktank.com>
rpm-autosign.exp [new file with mode: 0755]

diff --git a/rpm-autosign.exp b/rpm-autosign.exp
new file mode 100755 (executable)
index 0000000..0e2541f
--- /dev/null
@@ -0,0 +1,9 @@
+#!/usr/bin/expect -f
+
+# First parameter should be the key such as:
+#   --define "_gpg_name 03C3951A"
+
+spawn rpm --addsign {*}$argv
+expect -exact "Enter pass phrase: "
+send -- "\r"
+expect eof