batch signing rpm packages

Linux, Unix, Windows..

Moderator: Moderators

batch signing rpm packages

Postby zoli » Mon Jan 21, 2008 11:44 am

hello,


Adding a signature looks like a trivial task, but once you want to skip the manual interaction it start to be embracing.

It looks funny, but i could not find an usable script on the net to do this task, therefore I post mine in order to make the others life easier :)

Here is my small, dummy script for batch signing rpm packages. It requires expect and it does work :)

Code: Select all
#!/usr/bin/expect
# Expect script for batch signing rpm packages
#
set timeout -1
log_user 0
set rpm_file [lindex $argv 0]
set sig_password [lindex $argv 1]

spawn /usr/bin/rpmsign --addsign $rpm_file
expect "phrase: "
send "$sig_password\r"
expect eof
Regards,
Z
---
Zoltan Arpadffy
zoli
Forum Admin
Forum Admin
 
Posts: 784
Joined: Mon Sep 30, 2002 1:27 am
Location: Stockholm, Sweden

Return to Operating systems

Who is online

Users browsing this forum: No registered users and 10 guests

cron