However, when want to use the GPG key, I have an error:
<pre>
Signing file 'Release' with gpg, please enter your passphrase when prompted:
gpg: cannot open `/dev/tty': No such device or address
ERROR: unable to publish: unable to detached sign file: exit status 2
</pre>
This is due to the fact that aptly is not running in a terminal.
It's running from a script that calls a
<pre>
'bash','-c','aptly publish update -passphrase="mypassphrase" precise'
</pre>
This is a known issue in GPG, and can be solved easily by forcing the GPG command line with a --no-tty argument
However this command line is now "hidden" within the aptly code...
So, would it be possible to add to "aptly publish" call an additional --not-tty parameter to force the call to gpg...
Or any other solution?
Thanks
Damien
Hi,
Is it possible publish repo from the remote machine?
I am getting the same error even though I use batch flag.
# ssh aptly@aptly1 "/home/aptly/aptly_0.9.7_linux_amd64/aptly publish repo -batch=false -passphrase-file=/home/aptly/.gnupg/gpg_passphrase debian"
Loading packages...
Generating metadata files and linking package files...
Finalizing metadata files...
Signing file 'Release' with gpg, please enter your passphrase when prompted:
gpg: cannot open tty `/dev/tty': No such device or address
ERROR: unable to publish: unable to detached sign file: exit status 2
can you assist me to solve this issue?
Sorry. I misunderstood the batch option comments. It is worked when I try with -batch=true.
Thanks.