Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgraded to Micronaut 3.8.1 #5

Merged
merged 14 commits into from
Jan 17, 2023
26 changes: 16 additions & 10 deletions .github/workflows/on_pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,13 @@ jobs:
restore-keys: ${{ runner.os }}-gradle

- name: Build and analyze
id: build_jar
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
run: ./gradlew build jacocoTestReport sonarqube --info
run: |
./gradlew build jacocoTestReport sonarqube --info
echo current_version=$(echo $(./gradlew properties --no-daemon --console=plain -q | grep "^version:" | awk '{printf $2}')) >> $GITHUB_OUTPUT

- name: Publish test report
if: always()
Expand All @@ -49,7 +52,7 @@ jobs:
uses: actions/upload-artifact@v3
with:
name: kafkactl-jar
path: ${{ github.workspace }}/build/libs/kafkactl-*.jar
path: ${{ github.workspace }}/build/libs/kafkactl-${{ steps.build_jar.outputs.current_version }}.jar

build-linux:
runs-on: ubuntu-latest
Expand All @@ -62,7 +65,7 @@ jobs:
- name: Set up GraalVM
uses: graalvm/setup-graalvm@v1
with:
version: '21.1.0'
version: '22.3.0'
java-version: '11'
components: 'native-image'
github-token: ${{ secrets.GITHUB_TOKEN }}
Expand All @@ -81,14 +84,17 @@ jobs:
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle') }}
restore-keys: ${{ runner.os }}-gradle

- name: Native image
run: ./gradlew shadowJar nativeImage
- name: Build
id: build_native
run: |
./gradlew nativeCompile
echo current_version=$(echo $(./gradlew properties --no-daemon --console=plain -q | grep "^version:" | awk '{printf $2}')) >> $GITHUB_OUTPUT

- name: Upload
uses: actions/upload-artifact@v3
with:
name: kafkactl-linux
path: ${{ github.workspace }}/build/native-image/kafkactl-*
path: ${{ github.workspace }}/build/native/nativeCompile/kafkactl-${{ steps.build_native.outputs.current_version }}

build-windows:
runs-on: windows-latest
Expand All @@ -101,7 +107,7 @@ jobs:
- name: Set up GraalVM
uses: graalvm/setup-graalvm@v1
with:
version: '20.3.2'
version: '22.3.0'
java-version: '11'
components: 'native-image'
github-token: ${{ secrets.GITHUB_TOKEN }}
Expand All @@ -118,12 +124,12 @@ jobs:

- name: Build
run: |
call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" x86_amd64
gradlew.bat shadowJar nativeImage
call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvars64.bat"
gradlew.bat nativeCompile
shell: cmd

- name: Upload
uses: actions/upload-artifact@v3
with:
name: kafkactl-windows
path: ${{ github.workspace }}/build/native-image/kafkactl-*.exe
path: ${{ github.workspace }}/build/native/nativeCompile/kafkactl-*.exe
28 changes: 17 additions & 11 deletions .github/workflows/on_push_main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,13 @@ jobs:
restore-keys: ${{ runner.os }}-gradle

- name: Build and analyze
id: build_jar
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
run: ./gradlew build jacocoTestReport sonarqube --info
run: |
./gradlew build jacocoTestReport sonarqube --info
echo current_version=$(echo $(./gradlew properties --no-daemon --console=plain -q | grep "^version:" | awk '{printf $2}')) >> $GITHUB_OUTPUT

- name: Publish test report
if: always()
Expand All @@ -58,7 +61,7 @@ jobs:
uses: actions/upload-artifact@v3
with:
name: kafkactl-jar
path: ${{ github.workspace }}/build/libs/kafkactl-*.jar
path: ${{ github.workspace }}/build/libs/kafkactl-${{ steps.build_jar.outputs.current_version }}.jar

build-linux:
runs-on: ubuntu-latest
Expand All @@ -71,7 +74,7 @@ jobs:
- name: Set up GraalVM
uses: graalvm/setup-graalvm@v1
with:
version: '21.1.0'
version: '22.3.0'
java-version: '11'
components: 'native-image'
github-token: ${{ secrets.GITHUB_TOKEN }}
Expand All @@ -90,27 +93,30 @@ jobs:
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle') }}
restore-keys: ${{ runner.os }}-gradle

- name: Native image
run: ./gradlew shadowJar nativeImage
- name: Build
id: build_native
run: |
./gradlew nativeCompile
echo current_version=$(echo $(./gradlew properties --no-daemon --console=plain -q | grep "^version:" | awk '{printf $2}')) >> $GITHUB_OUTPUT

- name: Upload
uses: actions/upload-artifact@v3
with:
name: kafkactl-linux
path: ${{ github.workspace }}/build/native-image/kafkactl-*
path: ${{ github.workspace }}/build/native/nativeCompile/kafkactl-${{ steps.build_native.outputs.current_version }}

build-windows:
runs-on: windows-latest
steps:
- name: Checkout project
uses: actions/checkout@v3
with:
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
fetch-depth: 0

- name: Set up GraalVM
uses: graalvm/setup-graalvm@v1
with:
version: '20.3.2'
version: '22.3.0'
java-version: '11'
components: 'native-image'
github-token: ${{ secrets.GITHUB_TOKEN }}
Expand All @@ -127,12 +133,12 @@ jobs:

- name: Build
run: |
call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" x86_amd64
gradlew.bat shadowJar nativeImage
call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvars64.bat"
gradlew.bat nativeCompile
shell: cmd

- name: Upload
uses: actions/upload-artifact@v3
with:
name: kafkactl-windows
path: ${{ github.workspace }}/build/native-image/kafkactl-*.exe
path: ${{ github.workspace }}/build/native/nativeCompile/kafkactl-*.exe
49 changes: 16 additions & 33 deletions .github/workflows/on_push_tag.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,10 @@ jobs:
restore-keys: ${{ runner.os }}-gradle

- name: Build and test
id: build_and_test
id: build_jar
run: |
./gradlew build check -Prelease
echo ::set-output name=current_version::$(echo $(./gradlew properties --no-daemon --console=plain -q | grep "^version:" | awk '{printf $2}'))
./gradlew build check
echo current_version=$(echo $(./gradlew properties --no-daemon --console=plain -q | grep "^version:" | awk '{printf $2}')) >> $GITHUB_OUTPUT

- name: Publish test report
if: always()
Expand All @@ -45,15 +45,9 @@ jobs:
report_paths: '**/build/test-results/test/TEST-*.xml'

- name: Docker
run: ./gradlew dockerBuild dockerPush -Prelease
run: ./gradlew dockerBuild dockerPush

- name: Upload
uses: actions/upload-artifact@v3
with:
name: kafkactl-jar
path: ${{ github.workspace }}/build/libs/kafkactl-*.jar

- name: Generate Release Changelog
- name: Generate release changelog
uses: mikepenz/release-changelog-builder-action@v1
id: build_changelog
with:
Expand All @@ -66,7 +60,7 @@ jobs:
with:
token: ${{ secrets.GITHUB_TOKEN }}
body: ${{ steps.build_changelog.outputs.changelog }}
artifacts: ${{ github.workspace }}/cli/build/libs/kafkactl-*.jar
artifacts: ${{ github.workspace }}/cli/build/libs/kafkactl-${{ steps.build_jar.outputs.current_version }}.jar
draft: true
prerelease: true
allowUpdates: true
Expand All @@ -82,7 +76,7 @@ jobs:
- name: Set up GraalVM
uses: graalvm/setup-graalvm@v1
with:
version: '21.1.0'
version: '22.3.0'
java-version: '11'
components: 'native-image'
github-token: ${{ secrets.GITHUB_TOKEN }}
Expand All @@ -95,20 +89,16 @@ jobs:
restore-keys: ${{ runner.os }}-gradle

- name: Build
run: ./gradlew shadowJar nativeImage -Prelease

- name: Upload
uses: actions/upload-artifact@v3
with:
name: kafkactl-linux
path: ${{ github.workspace }}/build/native-image/kafkactl-*
id: build_native
run: |
./gradlew nativeCompile
echo current_version=$(echo $(./gradlew properties --no-daemon --console=plain -q | grep "^version:" | awk '{printf $2}')) >> $GITHUB_OUTPUT

- name: Update release
uses: ncipollo/release-action@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
body: ${{ steps.build_changelog.outputs.changelog }}
artifacts: ${{ github.workspace }}/build/native-image/kafkactl-${{ steps.build_and_test.outputs.current_version }}
artifacts: ${{ github.workspace }}/build/native/nativeCompile/kafkactl-${{ steps.build_native.outputs.current_version }}
draft: true
prerelease: true
allowUpdates: true
Expand All @@ -125,7 +115,7 @@ jobs:
- name: Set up GraalVM
uses: graalvm/setup-graalvm@v1
with:
version: '20.3.2'
version: '22.3.0'
java-version: '11'
components: 'native-image'
github-token: ${{ secrets.GITHUB_TOKEN }}
Expand All @@ -142,22 +132,15 @@ jobs:

- name: Build
run: |
call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" x86_amd64
gradlew.bat shadowJar nativeImage
call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvars64.bat"
gradlew.bat nativeCompile
shell: cmd

- name: Upload
uses: actions/upload-artifact@v3
with:
name: kafkactl-windows
path: ${{ github.workspace }}/build/native-image/kafkactl-*.exe

- name: Update release
uses: ncipollo/release-action@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
body: ${{ steps.build_changelog.outputs.changelog }}
artifacts: ${{ github.workspace }}/cli/build/native-image/kafkactl-*.exe
artifacts: ${{ github.workspace }}/build/native/nativeCompile/kafkactl-*.exe
draft: true
prerelease: true
allowUpdates: true
35 changes: 0 additions & 35 deletions build-native.md

This file was deleted.

Loading