diff options
| author | Jakub Beránek <berykubik@gmail.com> | 2025-05-20 15:16:16 +0200 |
|---|---|---|
| committer | Mark Rousskov <mark.simulacrum@gmail.com> | 2025-05-24 20:10:51 -0400 |
| commit | 1718bb2037fd1baafd2068b06309e9be6bdc2a65 (patch) | |
| tree | e4361b8238caa35f756434cb811e429baf903ecd | |
| parent | 53458c89cebc02fb3019081a58c3232c5c5dd60a (diff) | |
| download | rust-1718bb2037fd1baafd2068b06309e9be6bdc2a65.tar.gz rust-1718bb2037fd1baafd2068b06309e9be6bdc2a65.zip | |
Add bors environment to CI
This will be used to access secrets once we move off rust-lang-ci.
| -rw-r--r-- | .github/workflows/ci.yml | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1b8b6eabdc5..566ae223500 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -73,6 +73,15 @@ jobs: needs: [ calculate_matrix ] runs-on: "${{ matrix.os }}" timeout-minutes: 360 + # The bors environment contains secrets required for elevated workflows (try and auto builds), + # which need to access e.g. S3 and upload artifacts. We want to provide access to that + # environment only on the try/auto branches, which are only accessible to bors. + # This also ensures that PR CI (which doesn't get write access to S3) works, as it cannot + # access the environment. + # + # We only enable the environment for the rust-lang/rust repository, so that rust-lang-ci/rust + # CI works until we migrate off it (since that repository doesn't contain the environment). + environment: ${{ ((github.repository == 'rust-lang/rust' && (github.ref == 'refs/heads/try' || github.ref == 'refs/heads/auto')) && 'bors') || '' }} env: CI_JOB_NAME: ${{ matrix.name }} CI_JOB_DOC_URL: ${{ matrix.doc_url }} |
