[Build] Try native arm build #220
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 uses actions that are not certified by GitHub. | |
# They are provided by a third-party and are governed by | |
# separate terms of service, privacy policy, and support | |
# documentation. | |
# GitHub recommends pinning actions to a commit SHA. | |
# To get a newer version, you will need to update the SHA. | |
# You can also reference a tag or branch, but the action may change without warning. | |
name: Java CI | |
on: | |
push: | |
tags: | |
- '**' | |
branches: | |
- 'native-arm' | |
jobs: | |
main-build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up JDK 23 | |
uses: actions/setup-java@v4 | |
with: | |
java-version: '23' | |
distribution: 'temurin' | |
- name: Setup Gradle for a non-wrapper project | |
uses: gradle/actions/setup-gradle@v4 | |
with: | |
gradle-version: 8.10.1 | |
- name: Build JVM OCI image | |
if: "${{github.ref_name != 'native-arm'}}" | |
run: gradle jib | |
env: | |
USERNAME: ${{ github.actor }} | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
DOCKERHUB_USER: ${{ secrets.DOCKERHUB_USER }} | |
DOCKERHUB_PASSWORD: ${{ secrets.DOCKERHUB_PASSWORD }} | |
- name: Build Native OCI Image | |
run: gradle bootBuildImage | |
env: | |
USERNAME: ${{ github.actor }} | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
DOCKERHUB_USER: ${{ secrets.DOCKERHUB_USER }} | |
DOCKERHUB_PASSWORD: ${{ secrets.DOCKERHUB_PASSWORD }} | |
- name: Gradle native arm64 | |
uses: uraimo/run-on-arch-action@v2 | |
with: | |
arch: aarch64 | |
distro: ubuntu_latest | |
githubToken: ${{ secrets.GITHUB_TOKEN }} | |
run: ./gradlew bootBuildImage --publishImage | |