Support of Spring RabbitMQ #100
Workflow file for this run
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: Build and Deploy | |
on: | |
pull_request: | |
branches: [ main ] | |
push: | |
branches: [ main ] | |
tags: | |
- '*' | |
permissions: | |
checks: write | |
contents: read | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
packages: write | |
checks: write | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up JDK 23 | |
uses: actions/setup-java@v4 | |
with: | |
java-version: '23' | |
distribution: 'adopt' | |
- name: Validate Gradle wrapper | |
uses: gradle/wrapper-validation-action@f9c9c575b8b21b6485636a91ffecd10e558c62f6 | |
- name: Build with Gradle | |
run: | | |
./gradlew build | |
./gradlew contractTest | |
- name: Test Report | |
uses: dorny/test-reporter@v1 | |
if: success() || failure() | |
with: | |
name: JUnit Tests | |
path: "*/build/test-results/*/*.xml" | |
reporter: java-junit | |
fail-on-error: true | |
create-release: | |
needs: build | |
runs-on: ubuntu-latest | |
if: startsWith(github.ref, 'refs/tags/') && !github.base_ref | |
permissions: | |
contents: write | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: ncipollo/release-action@v1 | |
with: | |
generateReleaseNotes: true | |
deploy: | |
needs: create-release | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
packages: write | |
checks: write | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up JDK 23 | |
uses: actions/setup-java@v4 | |
with: | |
java-version: '23' | |
distribution: 'adopt' | |
- name: Validate Gradle wrapper | |
uses: gradle/wrapper-validation-action@f9c9c575b8b21b6485636a91ffecd10e558c62f6 | |
- name: Deploy with JReleaser | |
env: | |
MAVEN_CENTRAL_USERNAME: ${{ secrets.MAVEN_CENTRAL_USERNAME }} | |
MAVEN_CENTRAL_PASSWORD: ${{ secrets.MAVEN_CENTRAL_PASSWORD }} | |
JRELEASER_GPG_PASSPHRASE: ${{ secrets.JRELEASER_GPG_PASSPHRASE }} | |
JRELEASER_GPG_SECRET_KEY: ${{ secrets.JRELEASER_GPG_SECRET_KEY }} | |
JRELEASER_GPG_PUBLIC_KEY: ${{ secrets.JRELEASER_GPG_PUBLIC_KEY }} | |
run: | | |
./gradlew publish | |
./gradlew :pact-jvm-mock:jreleaserDeploy & ./gradlew :pact-jvm-mock-mockk:jreleaserDeploy & ./gradlew :pact-jvm-mock-spring:jreleaserDeploy & ./gradlew :pact-jvm-mock-mockito:jreleaserDeploy |