mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-20 21:14:14 +08:00
Login to Meta's ECR when using non-meta runner (#132870)
The project depends on fetching container images from Meta's ECR repo so when run on non-meta runners we need to ensure that we also login to Meta's ECR too. Closes pytorch/ci-infra#252. Pull Request resolved: https://github.com/pytorch/pytorch/pull/132870 Approved by: https://github.com/ZainRizvi
This commit is contained in:
committed by
PyTorch MergeBot
parent
4a4dc9d6d9
commit
dfc5bb0099
7
.github/actions/setup-linux/action.yml
vendored
7
.github/actions/setup-linux/action.yml
vendored
@ -59,6 +59,13 @@ runs:
|
||||
aws ecr get-login-password --region "$AWS_DEFAULT_REGION" | docker login --username AWS \
|
||||
--password-stdin "$AWS_ACCOUNT_ID.dkr.ecr.$AWS_DEFAULT_REGION.amazonaws.com"
|
||||
|
||||
# For LF Runners we need to make sure we also login to Meta's ECR docker registry too.
|
||||
META_AWS_ACCOUNT_ID=308535385114
|
||||
if [ "$AWS_ACCOUNT_ID" != "$META_AWS_ACCOUNT_ID" ] ; then
|
||||
aws ecr get-login-password --region "$AWS_DEFAULT_REGION" | docker login --username AWS \
|
||||
--password-stdin "$META_AWS_ACCOUNT_ID.dkr.ecr.$AWS_DEFAULT_REGION.amazonaws.com"
|
||||
fi
|
||||
|
||||
- name: Preserve github env variables for use in docker
|
||||
shell: bash
|
||||
run: |
|
||||
|
Reference in New Issue
Block a user