The infrastructure team manages an instance of Homu called "Bors", to be used
by repositories inside the
rust-lang organization. The instance is available
at bors.rust-lang.org, and is backed by the @bors GitHub account.
Homu is quite buggy, and it might happen that the queue doesn't reflect the actual state in the repositories. This can be fixed by pressing the "Synchronize" button in the queue page. Note that the synchronization process itself is a bit buggy, and it might happen that PRs which were approved but failed are re-approved again on their own.
There are multiple steps needed to add a repository to our Bors instance:
The @bors GitHub account needs to be granted write access to the repository.
Each CI provider needs to have a single GitHub Check Run to gate on. This is not provided by default on GitHub Actions, but it can be simulated with these two jobs, which will generate a
bors build finishedcheck:
end-success: name: bors build finished if: success() runs-on: ubuntu-latest needs: [ALL, OTHER, JOBS] steps: - name: Mark the job as successful run: exit 0 end-failure: name: bors build finished if: "!success()" runs-on: ubuntu-latest needs: [ALL, OTHER, JOBS] steps: - name: Mark the job as a failure run: exit 1
Make sure to replace
[ALL, OTHER, JOBS]with a list of all the jobs you want to gate on.
Add the repository name to the
permissions!macro in the team repository, and grant the
bors.REPOSITORY.reviewpermission to the right people.
Add the repository to the
repositoriesmap in the Terraform configuration file. This will create a webhook and inject its secret key in the bors execution environment.
Add the repository to the Bors configuration, taking inspiration from other repositories.