Skip to content

Commit c1da277

Browse files
mattockmmoll
authored andcommitted
Fix issue that prevented freight-cache from working with GnuPG 2.x
URL: #72 Signed-off-by: Samuli Seppänen <samuli@openvpn.net>
1 parent 78949f8 commit c1da277

2 files changed

Lines changed: 9 additions & 0 deletions

File tree

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,10 @@ Build the cache of all the files needed to be accepted as a Debian archive:
2727

2828
freight cache
2929

30+
If your system has GnuPG 2.x make sure that a gpg-agent is running or the above
31+
command will fail. Also make sure you have installed a pinentry package (e.g.
32+
pinentry-curses) that suits your needs.
33+
3034
Serve `/var/cache/freight` via your favorite web server and install it as an APT source:
3135

3236
echo "deb http://example.com $(lsb_release -sc) main" | sudo tee /etc/apt/sources.list.d/example.list

lib/freight/apt.sh

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -207,6 +207,11 @@ EOF
207207

208208
} >"$DISTCACHE/Release"
209209

210+
# Pinentry may fail on GnuPG 2.x without GPG_TTY, see
211+
# https://github.com/freight-team/freight/issues/72
212+
GPG_TTY=$(tty)
213+
export GPG_TTY
214+
210215
# Sign the top-level `Release` file with `gpg`, for each key and
211216
# concatenate signatures.
212217
for GPGKEY in $GPG; do

0 commit comments

Comments
 (0)