Skip to content

Workflow file for this run

name: Deploy to Nexus Repository
on:
release:
types: [published]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Set up JDK 16
uses: actions/setup-java@v1
with:
java-version: 20
- name: Set env
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
- name: Build with Maven
run: mvn package --file pom.xml
- name: Nexus Repo Publish
uses: sonatype-nexus-community/nexus-repo-github-action@master
with:
serverUrl: https://nexus.golden-developer.de
username: github
password: ${{ secrets.NEXUS_PASSWORD }}
format: maven2
repository: maven-releases
coordinates: groupId=de.goldendeveloper artifactId=MYSQL-Api version=${{ env.RELEASE_VERSION }}
assets: extension=jar
filename: ./target/MYSQL-Api-${{ env.RELEASE_VERSION }}.jar