From 9016e00e7bf170f31d025eff838cfb5209bbdd57 Mon Sep 17 00:00:00 2001 From: Antoine Cotten Date: Thu, 26 Aug 2021 00:55:53 +0200 Subject: [PATCH] Revert "Send automated PR upon new stack release" This reverts commit 730ffa8de5f4f7c7c95d8a674744a0e09fe072ba. Lately, Elastic's release pipeline has been tagging releases from the older 6.x series as "latest" in place of releases from the current 7.x series. This results in weekly PRs from GitHub Actions for _downgrading_ our stack from 7.x to 6.x. In order to avoid receiving those PRs, we disable the update workflow entirely until the Elastic 6.x release series is marked as EOL. Ref. elastic/elasticsearch#75436 Closes #611 --- .github/workflows/update.yml | 45 ------------------------------------ 1 file changed, 45 deletions(-) delete mode 100644 .github/workflows/update.yml diff --git a/.github/workflows/update.yml b/.github/workflows/update.yml deleted file mode 100644 index d9b2480..0000000 --- a/.github/workflows/update.yml +++ /dev/null @@ -1,45 +0,0 @@ -name: Update Elastic release - -on: - schedule: - - cron: '0 0 * * 0' # At 00:00 every Sunday - -jobs: - - check-and-update: - name: Check and update Elastic release - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v2 - - - name: Get latest release version - uses: octokit/request-action@v2.x - id: get_latest_release - with: - route: GET /repos/:repository/releases/latest - repository: elastic/elasticsearch - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - name: Update stack version - run: | - source .env - cur_ver="$ELK_VERSION" - new_ver=${{ fromJson(steps.get_latest_release.outputs.data).tag_name }} - - # Escape dot characters so sed interprets them as literal dots - cur_ver="$(echo $cur_ver | sed 's/\./\\./g')" - # Trim leading 'v' in semantic version - new_ver="${new_ver:1}" - - for f in .env docker-stack.yml README.md; do - sed -i "s/${cur_ver}/${new_ver}/g" "$f" - done - - - name: Send pull request to update to new version - uses: peter-evans/create-pull-request@v3 - with: - commit-message: Update to ${{ fromJson(steps.get_latest_release.outputs.data).tag_name }} - title: Update to ${{ fromJson(steps.get_latest_release.outputs.data).tag_name }} - delete-branch: true