1.a Build & Deploy Nexus Artifact #3
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: 1.a Build & Deploy Nexus Artifact | |
on: | |
workflow_dispatch: | |
push: | |
branches: [ "main" ] | |
env: | |
REGISTRY: ghcr.io | |
jobs: | |
build: | |
name: Build | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Maven Central Repository | |
uses: actions/setup-java@v4 | |
with: | |
java-version: '21' | |
distribution: 'zulu' | |
- name: Setup Gradle | |
uses: gradle/gradle-build-action@v3 | |
- name: Build & Publish Package | |
run: ./gradlew clean build publish --stacktrace | |
env: | |
OSSRH_USERNAME: ${{ secrets.OSSRH_USERNAME }} | |
OSSRH_PASSWORD: ${{ secrets.OSSRH_PASSWORD }} | |
OSSRH_PGP_PRIVATE_KEY: ${{ secrets.OSSRH_PGP_PRIVATE_KEY }} | |
OSSRH_PGP_SECRET_KEY_PASSPHRASE: ${{ secrets.OSSRH_PGP_SECRET_KEY_PASSPHRASE }} |