Merge pull request #422 from rabbitmq/dependabot/maven/org.apache.mav… #150
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: Test against RabbitMQ 3.12 stable | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up JDK | |
uses: actions/setup-java@v4 | |
with: | |
distribution: 'zulu' | |
java-version: '21' | |
cache: 'maven' | |
server-id: ossrh | |
server-username: MAVEN_USERNAME | |
server-password: MAVEN_PASSWORD | |
gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} | |
gpg-passphrase: MAVEN_GPG_PASSPHRASE | |
- name: Start RabbitMQ | |
run: ci/start-broker.sh | |
- name: Configure broker | |
run: HOP_RABBITMQCTL=DOCKER:rabbitmq ci/before-build.sh | |
- name: Show version | |
run: ./mvnw --version | |
- name: Test | |
run: ./mvnw test --no-transfer-progress | |
- name: Stop broker | |
run: docker stop rabbitmq && docker rm rabbitmq | |
- name: Publish snapshot | |
run: ./mvnw clean deploy -Psnapshots -DskipITs -DskipTests --no-transfer-progress | |
if: ${{ github.event_name != 'pull_request' }} | |
env: | |
MAVEN_USERNAME: ${{ secrets.OSSRH_USERNAME }} | |
MAVEN_PASSWORD: ${{ secrets.OSSRH_TOKEN }} | |
MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }} |