Skip to content

Commit

Permalink
ci: Remove Bors (#13715)
Browse files Browse the repository at this point in the history
# Description

This PR removes Bors in favor of native GitHub merge queues. A very
similar
cutover was tested and verified in
pulumi/watchutil-rs#39.

# Deployment plan

* [x] Find some time where PRs aren't being merged. This is mostly to
minimize confusion
  while we're futzing with branch protections. 
* [x] Update the repo's branch protection rules to match
  pulumi/watchutil-rs#38:
* "Allow specified actors to bypass required pull requests": "bors" →
Unchecked
    * "Status checks that are required": "bors" → "ci-ok"
    * "Require merge queue": Unchecked → Checked
        * "Only merge non-failing pull requests" → Unchecked
        * "Merge method" → Squash and merge
* [ ] Merge this PR using the "Merge when ready" button.
* [ ] If it merges successfully: confirm the prepare-release step ran
and published
      pre-release artifacts.
* [ ] If the merge fails: it's possible we'll need to tweak steps
slightly
(e.g. if the step's name doesn't match the branch protection rule). The
      end goal is a "ci-ok" step in both the PR and merge workflows that
      captures whether everything is green.
* [ ] If the issues aren't immediately resolvable, revert the changes
made
to branch protection settings. Folks will continue to merge with
          Bors.

If all goes well, we should be able to continue merging with MQ for a
while --
at least long enough to cut a new CLI release. Once we're confident we
won't
need to roll back:
* [ ] Delete branch protection rules for:
    * staging
    * testing
* [ ] Remove pu/pu from https://app.bors.tech/repositories

Fixes #13501

## Checklist

- [ ] I have run `make tidy` to update any new dependencies
- [ ] I have run `make lint` to verify my code passes the lint check
  - [ ] I have formatted my code using `gofumpt`

<!--- Please provide details if the checkbox below is to be left
unchecked. -->
- [ ] I have added tests that prove my fix is effective or that my
feature works
<!---
User-facing changes require a CHANGELOG entry.
-->
- [ ] I have run `make changelog` and committed the
`changelog/pending/<file>` documenting my change
<!--
If the change(s) in this PR is a modification of an existing call to the
Pulumi Cloud,
then the service should honor older versions of the CLI where this
change would not exist.
You must then bump the API version in
/pkg/backend/httpstate/client/api.go, as well as add
it to the service.
-->
- [ ] Yes, there are changes in this PR that warrants bumping the Pulumi
Cloud API version
<!-- @pulumi employees: If yes, you must submit corresponding changes in
the service repo. -->
  • Loading branch information
blampe committed Aug 12, 2023
1 parent 6c2c2cf commit 41b436d
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 33 deletions.
15 changes: 0 additions & 15 deletions .github/workflows/on-merge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,6 @@ permissions:

on:
merge_group:
push:
branches:
- staging
- trying
tags-ignore:
- "*"

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
Expand Down Expand Up @@ -49,7 +43,6 @@ jobs:

prepare-release:
name: prepare
if: github.ref_name == 'staging' || github.event_name == 'merge_group' # only on real merges
needs: [info, ci]
uses: ./.github/workflows/ci-prepare-release.yml
permissions:
Expand All @@ -63,14 +56,6 @@ jobs:
project: ${{ github.repository }}
secrets: inherit

bors-ok:
name: bors-ok
needs: [prepare-release]
runs-on: ubuntu-latest
steps:
- name: CI succeeded
run: exit 0

ci-ok:
name: ci-ok
needs: [prepare-release]
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/on-pr-target.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,5 @@ jobs:
ref: refs/pull/${{ github.event.pull_request.number }}/merge
fetch-depth: 0
- name: Check for non-linear history
if: false
run: ./scripts/git-linear-history-check.sh
2 changes: 1 addition & 1 deletion .github/workflows/on-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ jobs:

ci-ok:
name: ci-ok
needs: [prepare-release]
needs: [ci]
runs-on: ubuntu-latest
steps:
- name: CI succeeded
Expand Down
9 changes: 3 additions & 6 deletions .github/workflows/release-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,11 +75,8 @@ jobs:
git push origin "pkg/v${PULUMI_VERSION}"
git push -u origin HEAD
PR_BODY=""
PR=$(gh pr create --title "Changelog and go.mod updates for v${PULUMI_VERSION}")
if [ "${QUEUE_MERGE}" = "true" ]; then
PR_BODY="bors merge"
gh pr merge --auto "${PR}"
fi
gh pr create \
--title "Changelog and go.mod updates for v${PULUMI_VERSION}" \
--body "${PR_BODY}"
11 changes: 0 additions & 11 deletions bors.toml

This file was deleted.

0 comments on commit 41b436d

Please sign in to comment.