Skip to content

Commit 194b1b1

Browse files
authored
Fix GPG Signing error in building bins during release (#1775)
# Goal The goal of this PR is to fix GPG binary signing error in the release workflow. Closes #1774
1 parent 85b3c2e commit 194b1b1

File tree

1 file changed

+15
-2
lines changed

1 file changed

+15
-2
lines changed

.github/workflows/release.yml

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -179,6 +179,8 @@ jobs:
179179
# arch: arm64
180180
runs-on: ${{matrix.os}}
181181
container: ghcr.io/libertydsnp/frequency/ci-base-image:1.0.0
182+
env:
183+
SIGNING_SUBKEY_FINGERPRINT: B6327D1474C6392032870E8EFA4FD1E73A0FE707
182184
steps:
183185
- name: Check Out Repo
184186
uses: actions/checkout@v4
@@ -212,10 +214,21 @@ jobs:
212214
with:
213215
gpg_private_key: ${{secrets.FREQUENCY_PGP_SECRET_SUBKEYS}}
214216
passphrase: ${{secrets.FREQUENCY_PGP_MASTER_KEY_PASSWORD}}
215-
fingerprint: B6327D1474C6392032870E8EFA4FD1E73A0FE707 # signing subkey
217+
fingerprint: ${{env.SIGNING_SUBKEY_FINGERPRINT}}
218+
- name: List GPG Keys
219+
run: gpg -k; gpg -K
220+
# The error in this step may be due to expired signing subkey
221+
# See https://github.com/LibertyDSNP/frequency/issues/1695
216222
- name: Generate Binary Signature
217223
working-directory: ${{env.BIN_DIR}}
218-
run: gpg --detach-sign --armor ${{env.RELEASE_BIN_FILENAME}}
224+
run: |
225+
gpg --version
226+
gpg --local-user ${{env.SIGNING_SUBKEY_FINGERPRINT}} \
227+
--sign --armor \
228+
--pinentry-mode=loopback \
229+
--passphrase="${{secrets.FREQUENCY_PGP_MASTER_KEY_PASSWORD}}" \
230+
--detach-sig \
231+
${{env.RELEASE_BIN_FILENAME}}
219232
- name: Verify Binary
220233
working-directory: ${{env.BIN_DIR}}
221234
run: gpg --verify ${{env.RELEASE_BIN_FILENAME}}.asc

0 commit comments

Comments
 (0)