From 1841d3f90907b77ac75d76ae456f32d64de17660 Mon Sep 17 00:00:00 2001 From: pzurek Date: Wed, 13 Sep 2023 11:27:35 +0200 Subject: [PATCH] Try to trigger missed [publish] job for the 7.4.1.1 --- .github/workflows/master_release.yml | 266 +++++++++++++-------------- 1 file changed, 132 insertions(+), 134 deletions(-) diff --git a/.github/workflows/master_release.yml b/.github/workflows/master_release.yml index 645fb5becd..83bdacda02 100644 --- a/.github/workflows/master_release.yml +++ b/.github/workflows/master_release.yml @@ -3,8 +3,7 @@ name: Master/Release branch workflow on: push: branches: - - master - - release/** + - publish-7.4.1.1 schedule: - cron: '0 5 * * 3' @@ -26,114 +25,113 @@ env: DEVELOPMENT_VERSION: 7.4.1.2-SNAPSHOT jobs: - run_ci: - uses: ./.github/workflows/ci.yml - secrets: inherit +# run_ci: +# uses: ./.github/workflows/ci.yml +# secrets: inherit - docker_latest: - name: "Update latest and Single Pipeline - images" - runs-on: ubuntu-latest - needs: [run_ci] - if: > - !(failure() || cancelled()) && - !contains(github.event.head_commit.message, '[skip docker_latest]') && - github.ref_name == 'master' && github.event_name != 'pull_request' - services: - registry: - image: registry:2 - ports: - - 5000:5000 - steps: - - uses: actions/checkout@v3 - with: - persist-credentials: false - - uses: Alfresco/alfresco-build-tools/.github/actions/get-build-info@v1.35.2 - - uses: Alfresco/alfresco-build-tools/.github/actions/free-hosted-runner-disk-space@v1.35.2 - - uses: Alfresco/alfresco-build-tools/.github/actions/setup-java-build@v1.35.2 - - name: Set up QEMU - uses: docker/setup-qemu-action@v2 - with: - platforms: linux/amd64,linux/arm64 - - name: "Build" - timeout-minutes: ${{ fromJSON(env.GITHUB_ACTIONS_DEPLOY_TIMEOUT) }} - run: | - bash ./scripts/ci/init.sh - bash ./scripts/ci/build.sh -m - - name: Compute final build number - run: | - echo "COMPUTED_BUILD_NUMBER=$(( $BASE_BUILD_NUMBER + $BUILD_NUMBER ))" >> $GITHUB_ENV - - name: "Update images" - timeout-minutes: ${{ fromJSON(env.GITHUB_ACTIONS_DEPLOY_TIMEOUT) }} - run: mvn -B -V clean install -ntp -DskipTests -Dmaven.javadoc.skip=true -Dbuild-number=${COMPUTED_BUILD_NUMBER} -Pags -Ppush-docker-images,pipeline - - name: "Clean Maven cache" - run: bash ./scripts/ci/cleanup_cache.sh - - release: - name: "Release and Copy to S3 Staging Bucket" - runs-on: ubuntu-latest - needs: [docker_latest] - if: > - !(failure() || cancelled()) && - contains(github.event.head_commit.message, '[release]') && - github.event_name != 'pull_request' - services: - registry: - image: registry:2 - ports: - - 5000:5000 - steps: - - uses: actions/checkout@v3 - with: - persist-credentials: false - - uses: Alfresco/alfresco-build-tools/.github/actions/get-build-info@v1.35.2 - - uses: Alfresco/alfresco-build-tools/.github/actions/free-hosted-runner-disk-space@v1.35.2 - - uses: Alfresco/alfresco-build-tools/.github/actions/setup-java-build@v1.35.2 - - uses: actions/setup-python@v4 - - name: Set up QEMU - uses: docker/setup-qemu-action@v2 - with: - platforms: linux/amd64,linux/arm64 - - name: "Build" - timeout-minutes: ${{ fromJSON(env.GITHUB_ACTIONS_DEPLOY_TIMEOUT) }} - run: | - bash ./scripts/ci/init.sh - bash ./scripts/ci/build.sh -m - - uses: Alfresco/alfresco-build-tools/.github/actions/configure-git-author@v1.35.2 - with: - username: ${{ env.GIT_USERNAME }} - email: ${{ env.GIT_EMAIL }} - global: true - - name: Compute final build number - run: | - echo "COMPUTED_BUILD_NUMBER=$(( $BASE_BUILD_NUMBER + $BUILD_NUMBER ))" >> $GITHUB_ENV - - name: "Release" - timeout-minutes: ${{ fromJSON(env.GITHUB_ACTIONS_DEPLOY_TIMEOUT) }} - run: | - bash scripts/ci/verify_release_tag.sh - bash scripts/ci/maven_release.sh $COMPUTED_BUILD_NUMBER - bash scripts/ci/prepare_staging_deploy.sh - - name: "Clean Maven cache" - run: bash ./scripts/ci/cleanup_cache.sh - - name: "Configure AWS credentials" - uses: aws-actions/configure-aws-credentials@v1 - with: - aws-access-key-id: ${{ secrets.AWS_S3_STAGING_ACCESS_KEY }} - aws-secret-access-key: ${{ secrets.AWS_S3_STAGING_SECRET_KEY }} - aws-region: ${{ env.AWS_REGION }} - - name: "Deploy to S3 Staging Bucket" - run: | - aws s3 cp --acl private --recursive ./deploy_dir s3://alfresco-artefacts-staging/alfresco-content-services/release/${BRANCH_NAME}/${COMPUTED_BUILD_NUMBER} - aws s3 cp --acl private --recursive ./deploy_dir_share s3://alfresco-artefacts-staging/share/${RELEASE_VERSION} - aws s3 cp --acl private --recursive ./deploy_dir_ags s3://alfresco-artefacts-staging/enterprise/RM/${RELEASE_VERSION} - - bash scripts/ci/copy_share_image_to_docker_hub.sh - - echo "Finished release and deployed to https://s3.console.aws.amazon.com/s3/buckets/alfresco-artefacts-staging/alfresco-content-services/release/${BRANCH_NAME}/${COMPUTED_BUILD_NUMBER}" +# docker_latest: +# name: "Update latest and Single Pipeline - images" +# runs-on: ubuntu-latest +# needs: [run_ci] +# if: > +# !(failure() || cancelled()) && +# !contains(github.event.head_commit.message, '[skip docker_latest]') && +# github.ref_name == 'master' && github.event_name != 'pull_request' +# services: +# registry: +# image: registry:2 +# ports: +# - 5000:5000 +# steps: +# - uses: actions/checkout@v3 +# with: +# persist-credentials: false +# - uses: Alfresco/alfresco-build-tools/.github/actions/get-build-info@v1.35.2 +# - uses: Alfresco/alfresco-build-tools/.github/actions/free-hosted-runner-disk-space@v1.35.2 +# - uses: Alfresco/alfresco-build-tools/.github/actions/setup-java-build@v1.35.2 +# - name: Set up QEMU +# uses: docker/setup-qemu-action@v2 +# with: +# platforms: linux/amd64,linux/arm64 +# - name: "Build" +# timeout-minutes: ${{ fromJSON(env.GITHUB_ACTIONS_DEPLOY_TIMEOUT) }} +# run: | +# bash ./scripts/ci/init.sh +# bash ./scripts/ci/build.sh -m +# - name: Compute final build number +# run: | +# echo "COMPUTED_BUILD_NUMBER=$(( $BASE_BUILD_NUMBER + $BUILD_NUMBER ))" >> $GITHUB_ENV +# - name: "Update images" +# timeout-minutes: ${{ fromJSON(env.GITHUB_ACTIONS_DEPLOY_TIMEOUT) }} +# run: mvn -B -V clean install -ntp -DskipTests -Dmaven.javadoc.skip=true -Dbuild-number=${COMPUTED_BUILD_NUMBER} -Pags -Ppush-docker-images,pipeline +# - name: "Clean Maven cache" +# run: bash ./scripts/ci/cleanup_cache.sh +# +# release: +# name: "Release and Copy to S3 Staging Bucket" +# runs-on: ubuntu-latest +# needs: [docker_latest] +# if: > +# !(failure() || cancelled()) && +# contains(github.event.head_commit.message, '[release]') && +# github.event_name != 'pull_request' +# services: +# registry: +# image: registry:2 +# ports: +# - 5000:5000 +# steps: +# - uses: actions/checkout@v3 +# with: +# persist-credentials: false +# - uses: Alfresco/alfresco-build-tools/.github/actions/get-build-info@v1.35.2 +# - uses: Alfresco/alfresco-build-tools/.github/actions/free-hosted-runner-disk-space@v1.35.2 +# - uses: Alfresco/alfresco-build-tools/.github/actions/setup-java-build@v1.35.2 +# - uses: actions/setup-python@v4 +# - name: Set up QEMU +# uses: docker/setup-qemu-action@v2 +# with: +# platforms: linux/amd64,linux/arm64 +# - name: "Build" +# timeout-minutes: ${{ fromJSON(env.GITHUB_ACTIONS_DEPLOY_TIMEOUT) }} +# run: | +# bash ./scripts/ci/init.sh +# bash ./scripts/ci/build.sh -m +# - uses: Alfresco/alfresco-build-tools/.github/actions/configure-git-author@v1.35.2 +# with: +# username: ${{ env.GIT_USERNAME }} +# email: ${{ env.GIT_EMAIL }} +# global: true +# - name: Compute final build number +# run: | +# echo "COMPUTED_BUILD_NUMBER=$(( $BASE_BUILD_NUMBER + $BUILD_NUMBER ))" >> $GITHUB_ENV +# - name: "Release" +# timeout-minutes: ${{ fromJSON(env.GITHUB_ACTIONS_DEPLOY_TIMEOUT) }} +# run: | +# bash scripts/ci/verify_release_tag.sh +# bash scripts/ci/maven_release.sh $COMPUTED_BUILD_NUMBER +# bash scripts/ci/prepare_staging_deploy.sh +# - name: "Clean Maven cache" +# run: bash ./scripts/ci/cleanup_cache.sh +# - name: "Configure AWS credentials" +# uses: aws-actions/configure-aws-credentials@v1 +# with: +# aws-access-key-id: ${{ secrets.AWS_S3_STAGING_ACCESS_KEY }} +# aws-secret-access-key: ${{ secrets.AWS_S3_STAGING_SECRET_KEY }} +# aws-region: ${{ env.AWS_REGION }} +# - name: "Deploy to S3 Staging Bucket" +# run: | +# aws s3 cp --acl private --recursive ./deploy_dir s3://alfresco-artefacts-staging/alfresco-content-services/release/${BRANCH_NAME}/${COMPUTED_BUILD_NUMBER} +# aws s3 cp --acl private --recursive ./deploy_dir_share s3://alfresco-artefacts-staging/share/${RELEASE_VERSION} +# aws s3 cp --acl private --recursive ./deploy_dir_ags s3://alfresco-artefacts-staging/enterprise/RM/${RELEASE_VERSION} +# +# bash scripts/ci/copy_share_image_to_docker_hub.sh +# +# echo "Finished release and deployed to https://s3.console.aws.amazon.com/s3/buckets/alfresco-artefacts-staging/alfresco-content-services/release/${BRANCH_NAME}/${COMPUTED_BUILD_NUMBER}" publish: name: "Copy to S3 Release Bucket" runs-on: ubuntu-latest - needs: [release] if: > !(failure() || cancelled()) && contains(github.event.head_commit.message, '[publish]') && @@ -173,32 +171,32 @@ jobs: - name: "Clean Maven cache" run: bash ./scripts/ci/cleanup_cache.sh - update_downstream: - name: "Update acs-community-packaging (after release)" - runs-on: ubuntu-latest - needs: [publish] - if: > - !(failure() || cancelled()) && - (contains(github.event.head_commit.message, '[downstream]') || (contains(github.event.head_commit.message, '[release]') && - !contains(github.event.head_commit.message, '[no downstream]'))) && - github.event_name != 'pull_request' - steps: - - uses: actions/checkout@v3 - with: - persist-credentials: false - - uses: Alfresco/alfresco-build-tools/.github/actions/get-build-info@v1.35.2 - - uses: Alfresco/alfresco-build-tools/.github/actions/free-hosted-runner-disk-space@v1.35.2 - - uses: Alfresco/alfresco-build-tools/.github/actions/setup-java-build@v1.35.2 - - name: "Init" - run: bash ./scripts/ci/init.sh - - uses: Alfresco/alfresco-build-tools/.github/actions/configure-git-author@v1.35.2 - with: - username: ${{ env.GIT_USERNAME }} - email: ${{ env.GIT_EMAIL }} - global: true - - name: "Update downstream" - run: bash ./scripts/ci/update_downstream.sh - env: - COMMIT_MESSAGE: ${{ github.event.head_commit.message }} - - name: "Clean Maven cache" - run: bash ./scripts/ci/cleanup_cache.sh +# update_downstream: +# name: "Update acs-community-packaging (after release)" +# runs-on: ubuntu-latest +# needs: [publish] +# if: > +# !(failure() || cancelled()) && +# (contains(github.event.head_commit.message, '[downstream]') || (contains(github.event.head_commit.message, '[release]') && +# !contains(github.event.head_commit.message, '[no downstream]'))) && +# github.event_name != 'pull_request' +# steps: +# - uses: actions/checkout@v3 +# with: +# persist-credentials: false +# - uses: Alfresco/alfresco-build-tools/.github/actions/get-build-info@v1.35.2 +# - uses: Alfresco/alfresco-build-tools/.github/actions/free-hosted-runner-disk-space@v1.35.2 +# - uses: Alfresco/alfresco-build-tools/.github/actions/setup-java-build@v1.35.2 +# - name: "Init" +# run: bash ./scripts/ci/init.sh +# - uses: Alfresco/alfresco-build-tools/.github/actions/configure-git-author@v1.35.2 +# with: +# username: ${{ env.GIT_USERNAME }} +# email: ${{ env.GIT_EMAIL }} +# global: true +# - name: "Update downstream" +# run: bash ./scripts/ci/update_downstream.sh +# env: +# COMMIT_MESSAGE: ${{ github.event.head_commit.message }} +# - name: "Clean Maven cache" +# run: bash ./scripts/ci/cleanup_cache.sh