From 76df2d0305c7f6225aa013c3792acbdcf766f7ce Mon Sep 17 00:00:00 2001 From: dhruv Date: Tue, 20 Aug 2024 22:00:30 +0530 Subject: [PATCH] added log generation/uploading, changes java version Signed-off-by: dhruv --- .github/workflows/build.yaml | 21 +++++++++++++++------ .github/workflows/pr-build.yaml | 6 +++--- 2 files changed, 18 insertions(+), 9 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index e97c1b0d..b420274e 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -48,7 +48,7 @@ jobs: - name: Setup JDK uses: actions/setup-java@v4 with: - java-version: '11' + java-version: '17' distribution: 'semeru' - name: Print githash @@ -58,7 +58,7 @@ jobs: - name: Setup Gradle uses: gradle/actions/setup-gradle@v3 with: - gradle-version: 6.9.2 + gradle-version: 8.9 - name: Build Extensions source code with gradle if: github.event_name == 'push' @@ -69,12 +69,13 @@ jobs: ORG_GRADLE_PROJECT_signingKey: ${{ secrets.GPG_KEY }} ORG_GRADLE_PROJECT_signingPassword: ${{ secrets.GPG_PASSPHRASE }} run: | - gradle -b galasa-extensions-parent/build.gradle check publish \ + set -o pipefail + gradle -b galasa-extensions-parent/build.gradle check publish --info \ -PsourceMaven=https://development.galasa.dev/${{ env.ARGO_APP_BRANCH }}/maven-repo/framework \ -PcentralMaven=https://repo.maven.apache.org/maven2/ \ -PtargetMaven=${{ github.workspace }}/repo \ -PjacocoEnabled=true \ - -PisMainOrRelease=true + -PisMainOrRelease=true 2>&1 | tee build.log - name: Build Extensions source code with gradle if: github.event_name == 'workflow_dispatch' # Use the input values provided by the workflow dispatch. @@ -85,12 +86,20 @@ jobs: ORG_GRADLE_PROJECT_signingKey: ${{ secrets.GPG_KEY }} ORG_GRADLE_PROJECT_signingPassword: ${{ secrets.GPG_PASSPHRASE }} run: | - gradle -b galasa-extensions-parent/build.gradle check publish \ + set -o pipefail + gradle -b galasa-extensions-parent/build.gradle check publish --info \ -PsourceMaven=https://development.galasa.dev/${{ env.ARGO_APP_BRANCH }}/maven-repo/framework \ -PcentralMaven=https://repo.maven.apache.org/maven2/ \ -PtargetMaven=${{ github.workspace }}/repo \ -PjacocoEnabled=${{ inputs.jacocoEnabled }} \ - -PisMainOrRelease=${{ inputs.isMainOrRelease }} + -PisMainOrRelease=${{ inputs.isMainOrRelease }} 2>&1 | tee build.log + + - name: Upload Gradle Build Log + if: always() + uses: actions/upload-artifact@v4 + with: + name: gradle-build-log + path: build.log - name: Login to Github Container Registry uses: docker/login-action@v3 diff --git a/.github/workflows/pr-build.yaml b/.github/workflows/pr-build.yaml index e69138e1..6515d298 100644 --- a/.github/workflows/pr-build.yaml +++ b/.github/workflows/pr-build.yaml @@ -19,7 +19,7 @@ jobs: - name: Setup JDK uses: actions/setup-java@v4 with: - java-version: '11' + java-version: '17' distribution: 'semeru' - name: Print githash @@ -29,11 +29,11 @@ jobs: - name: Setup Gradle uses: gradle/actions/setup-gradle@v3 with: - gradle-version: 6.9.2 + gradle-version: 8.9 - name: Build Extensions source code with gradle run: | - gradle -b galasa-extensions-parent/build.gradle check publish \ + gradle -b galasa-extensions-parent/build.gradle check publish --info \ -PsourceMaven=https://development.galasa.dev/gh/maven-repo/framework \ -PcentralMaven=https://repo.maven.apache.org/maven2/ \ -PtargetMaven=${{ github.workspace }}/repo