From b065aef30887b59790caa6605165e25479663595 Mon Sep 17 00:00:00 2001 From: Vitor Cardoso Date: Wed, 13 Mar 2024 17:50:07 +0000 Subject: [PATCH] [HNC-578] - Create process for Pentaho CUST case builds --- .github/workflows/merge.yml | 51 ++++++++++++++++++++++++------------- 1 file changed, 34 insertions(+), 17 deletions(-) diff --git a/.github/workflows/merge.yml b/.github/workflows/merge.yml index fcb76ce..8760029 100644 --- a/.github/workflows/merge.yml +++ b/.github/workflows/merge.yml @@ -64,6 +64,16 @@ on: required: false type: string description: "For PDI plugin integration tests, path to the json file containing test scenarios for each plugin" + run_snapshot: + required: true + type: boolean + default: true + description: 'should the snapshot build run' + run_versioning: + required: true + type: boolean + default: true + description: 'should the versioning run on the RC build' env: VERSION: "${{ inputs.version }}" @@ -122,6 +132,7 @@ jobs: cp "${{ steps.common-maven.outputs.settings-file-path }}" /root/.m2 snapshot: + if: ${{ inputs.run_snapshot == 'true' }} name: Update Snapshots needs: setup-maven-settings @@ -191,10 +202,14 @@ jobs: - name: Determine version id: version run: | - version="${{ env.VERSION }}-${{ github.run_number }}" + version="${{ env.VERSION }}" + if [[ "${{ inputs.run_versioning}}" == "true" ]]; then + version="${version}-${{ github.run_number }}" + fi echo "current-version=$version" >> $GITHUB_OUTPUT - name: Version set + if: ${{ inputs.run_snapshot == 'true' }} run: | sed -i 's/BASE_VERSION/${{ env.BASE_VERSION }}/g' .github/release-versions.properties sed -i 's/BUILD_NBR/${{ github.run_number }}/g' .github/release-versions.properties @@ -256,22 +271,24 @@ jobs: - name: Create artifacts download links shell: bash run: | - jf config add artifactory --interactive=false --enc-password=false --basic-auth-only \ - --artifactory-url ${{ env.ARTIFACTORY_BASE_URL }} \ - --password ${{ env.NEXUS_DEPLOY_PASSWORD }} \ - --user ${{ env.NEXUS_DEPLOY_USER }} - - resp=$(jf rt search --props "build.name=${{ env.BUILD_NAME }};build.number=${{ github.run_number }}" \ - "*-${{ steps.version.outputs.current-version }}.zip") - - echo "| :gift: Files |" >> $GITHUB_STEP_SUMMARY - echo "|:----:|" >> $GITHUB_STEP_SUMMARY - - echo "$resp" | jq -r '.[].path' | while read -r path; do - link_text=$(echo "$path" | sed 's/.*\///') - echo "| [ $link_text ](${{ env.ARTIFACTORY_BASE_URL }}/$path) |" >> $GITHUB_STEP_SUMMARY; - done - +# jf config add artifactory --interactive=false --enc-password=false --basic-auth-only \ +# --artifactory-url ${{ env.ARTIFACTORY_BASE_URL }} \ +# --password ${{ env.NEXUS_DEPLOY_PASSWORD }} \ +# --user ${{ env.NEXUS_DEPLOY_USER }} +# +# resp=$(jf rt search --props "build.name=${{ env.BUILD_NAME }};build.number=${{ github.run_number }}" \ +# "*-${{ steps.version.outputs.current-version }}.zip") +# +# echo "| :gift: Files |" >> $GITHUB_STEP_SUMMARY +# echo "|:----:|" >> $GITHUB_STEP_SUMMARY +# +# echo "$resp" | jq -r '.[].path' | while read -r path; do +# link_text=$(echo "$path" | sed 's/.*\///') +# echo "| [ $link_text ](${{ env.ARTIFACTORY_BASE_URL }}/$path) |" >> $GITHUB_STEP_SUMMARY; +# done + + # TODO: Jfrog's build-info pmaven plugin needs to be added to root POM + echo "|[Full artifacts list](${{ env.ARTIFACTORY_HOST }}/ui/builds/${{ env.BUILD_NAME }}/${{ github.run_number }})|" >> $GITHUB_STEP_SUMMARY - name: Report notifications