Skip to content

Migrate update-s3-html job to test-infra #1

Migrate update-s3-html job to test-infra

Migrate update-s3-html job to test-infra #1

Workflow file for this run

name: Update S3 HTML indices for download.pytorch.org
on:
pull_request:
paths:
- .github/workflows/update-s3-html.yml
schedule:
# Update the indices every 30 minutes
- cron: "*/30 * * * *"
workflow_dispatch:
permissions:
id-token: write
contents: read
jobs:
update:
runs-on: ubuntu-22.04
environment: pytorchbot-env
strategy:
matrix:
prefix: ["whl", "whl/test", "whl/nightly", "whl/lts/1.8"]
fail-fast: False
container:
image: continuumio/miniconda3:4.12.0
steps:
- name: configure aws credentials
id: aws_creds
uses: aws-actions/configure-aws-credentials@v3
with:
role-to-assume: arn:aws:iam::308535385114:role/gha_workflow_s3_update
aws-region: us-east-1
- name: Checkout repository test-infra
uses: actions/checkout@v3
with:
repository: pytorch/test-infra
ref: ${{ github.ref }}
- name: Update s3 html index
run: |
set -ex
# Create Conda Environment
conda create --quiet -y --prefix run_env python="3.8"
conda activate ./run_env
# Install requirements
pip install -r s3_management/requirements.txt
python s3_management/manage.py --generate-pep503 ${{ matrix.prefix }}