Skip to content

Commit 43d0886

Browse files
Update GitHub Deploy config
1 parent 1e57c67 commit 43d0886

1 file changed

Lines changed: 21 additions & 12 deletions

File tree

.github/workflows/deploy.yml

Lines changed: 21 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -13,18 +13,6 @@ jobs:
1313
- name: Checkout code
1414
uses: actions/checkout@v4
1515

16-
- name: Set up Java
17-
uses: actions/setup-java@v4
18-
with:
19-
distribution: 'temurin'
20-
java-version: '17'
21-
cache: 'maven'
22-
server-id: central
23-
server-username: ${{ secrets.CENTRAL_USERNAME }}
24-
server-password: ${{ secrets.CENTRAL_PASSWORD }}
25-
gpg-private-key: ${{ secrets.GPG_PRIVATE_KEY }}
26-
gpg-passphrase: ${{ secrets.GPG_PASSPHRASE }}
27-
2816
- name: Set up GPG
2917
run: |
3018
echo "$GPG_PRIVATE_KEY" | gpg --batch --import
@@ -36,6 +24,27 @@ jobs:
3624
- name: Verify GPG Key
3725
run: gpg --list-secret-keys --keyid-format LONG
3826

27+
- name: Set Default GPG Key
28+
run: gpg --default-key ${{ secrets.GPG_KEY_ID }}
29+
30+
- name: Debug GPG Key Import
31+
run: |
32+
echo "$GPG_PRIVATE_KEY" | gpg --batch --import
33+
gpg --list-secret-keys --keyid-format LONG || echo "No secret keys found"
34+
env:
35+
GPG_PRIVATE_KEY: ${{ secrets.GPG_PRIVATE_KEY }}
36+
37+
- name: Set up Java
38+
uses: actions/setup-java@v4
39+
with:
40+
distribution: 'temurin'
41+
java-version: '17'
42+
cache: 'maven'
43+
server-id: central
44+
server-username: ${{ secrets.CENTRAL_USERNAME }}
45+
server-password: ${{ secrets.CENTRAL_PASSWORD }}
46+
gpg-private-key: ${{ secrets.GPG_PRIVATE_KEY }}
47+
gpg-passphrase: ${{ secrets.GPG_PASSPHRASE }}
3948

4049
- name: Build and Deploy
4150
run: mvn clean deploy -Psign-artifacts

0 commit comments

Comments
 (0)