Add deployment environment for docs and upload test stats (#107318)

Many thanks to this discussion comment for explaining why we don't need an environment for the calling workflow but the secret can still be used
https://github.com/orgs/community/discussions/25238#discussioncomment-3247035
Pull Request resolved: https://github.com/pytorch/pytorch/pull/107318
Approved by: https://github.com/huydhn, https://github.com/atalman
This commit is contained in:
Catherine Lee 2023-08-17 15:47:18 +00:00 committed by PyTorch MergeBot
parent aa9f6a4335
commit f96617fdcd
2 changed files with 2 additions and 0 deletions

View file

@ -39,6 +39,7 @@ jobs:
# Don't run on forked repos.
if: github.repository_owner == 'pytorch'
runs-on: ${{ matrix.runner }}
environment: ${{ (github.ref == 'refs/heads/main' || startsWith(github.event.ref, 'refs/tags/v')) && 'pytorchbot-env' || '' }}
strategy:
fail-fast: false
matrix:

View file

@ -87,6 +87,7 @@ jobs:
if: ${{ always() }}
runs-on: [self-hosted, linux.2xlarge]
continue-on-error: true
environment: pytorchbot-env
steps:
- name: Get our GITHUB_TOKEN API limit usage
env: