Bump amazoncorretto from cca97a4
to bc45b73
in /handle-occurrence-service
#638
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
# This workflow will build a Java project with Gradle and cache/restore any dependencies to improve the workflow execution time | |
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle | |
name: Build | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
permissions: | |
contents: read | |
jobs: | |
build_linux: | |
if: ${{ github.run_number != 1 }} | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v3.2.0 | |
- uses: gradle/wrapper-validation-action@f9c9c575b8b21b6485636a91ffecd10e558c62f6 # v3.5.0 | |
- name: Set up JDK | |
uses: actions/setup-java@2dfa2011c5b2a0f1489bf9e433881c92c1631f88 # v4.3.0 | |
with: | |
java-version: '17' | |
distribution: 'adopt' | |
- name: Setup Gradle | |
uses: gradle/gradle-build-action@ac2d340dc04d9e1113182899e983b5400c17cda1 # v3.5.0 | |
with: | |
gradle-home-cache-cleanup: true | |
- name: Build | |
env: | |
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }} | |
run: ./gradlew check coveralls | |
release: | |
if: github.event_name == 'push' | |
permissions: | |
contents: write | |
packages: write | |
needs: build_linux | |
runs-on: ubuntu-latest | |
concurrency: | |
group: "${{ github.repository }}-release" | |
steps: | |
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v3.2.0 | |
- name: Fetch version history | |
# Do NOT want to fetch all tags if building a specific tag. | |
# Doing so could result in code published with wrong version, if newer tags have been pushed | |
if: (!startsWith(github.ref, 'refs/tags/')) | |
run: git fetch --tag --unshallow | |
- name: Set up JDK | |
uses: actions/setup-java@2dfa2011c5b2a0f1489bf9e433881c92c1631f88 # v4.3.0 | |
with: | |
java-version: '17' | |
distribution: 'adopt' | |
- name: Setup Gradle | |
uses: gradle/gradle-build-action@ac2d340dc04d9e1113182899e983b5400c17cda1 # v3.5.0 | |
with: | |
gradle-home-cache-cleanup: true | |
- name: Login to GitHub Container Registry | |
uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 # v3.3.0 | |
with: | |
registry: ghcr.io | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: Increment patch number | |
run: | | |
./gradlew cV | |
./gradlew release clean | |
./gradlew cV | |
- name: Publish jars | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: ./gradlew publish | |
- name: Push Docker images | |
run: ./gradlew pushAppImage |