From 78ebe7d3aa6d0d2edfeedf9760a3b8956a5ac87d Mon Sep 17 00:00:00 2001 From: Shitikanth Kashyap Date: Tue, 24 Sep 2024 10:43:28 +0530 Subject: [PATCH] Add environment variables for GPG private key and passphrase --- .github/workflows/maven.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index 4b9e78f..c478589 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -28,14 +28,16 @@ jobs: java-version: '17' distribution: 'temurin' cache: maven - server-id: 'ossrh' + server-id: 'central' server-username: MAVEN_USERNAME server-password: MAVEN_PASSWORD - name: Build with Maven - run: ./mvnw -V -B deploy + run: ./mvnw -V -B deploy -Dgpg.signer=bc env: MAVEN_USERNAME: ${{ secrets.SONATYPE_USERNAME }} MAVEN_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }} + MAVEN_GPG_KEY: ${{ secrets.GPG_PRIVATE_KEY }} + MAVEN_GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }} # Optional: Uploads the full dependency graph to GitHub to improve the quality of Dependabot alerts this repository can receive - name: Update dependency graph