Release Wheels #6
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Release Wheels | |
| on: # yamllint disable-line rule:truthy | |
| workflow_dispatch: | |
| inputs: | |
| release-type: | |
| description: 'Release type' | |
| required: true | |
| type: choice | |
| options: | |
| - nightly | |
| - final | |
| default: nightly | |
| schedule: | |
| - cron: "0 4 * * *" # Everyday at 4:00am UTC/8:00pm PST | |
| jobs: | |
| trigger: | |
| runs-on: ubuntu-latest | |
| outputs: | |
| matrix-linux: ${{ steps.set-matrix.outputs.matrix-linux }} | |
| matrix-macos: ${{ steps.set-matrix.outputs.matrix-macos }} | |
| matrix-windows: ${{ steps.set-matrix.outputs.matrix-windows }} | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v6 | |
| - name: Configure matrix | |
| id: set-matrix | |
| run: | | |
| # Set Linux matrix | |
| echo ::group::Set Linux matrix | |
| filename=".github/workflows/utils/full_matrix_linux.json" | |
| matrix=$(jq -c '[.[] | { "torch-version": .["torch-version"], "python-version": .["python-version"][], "cuda-version": .["cuda-version"][] }]' $filename) | |
| echo "matrix-linux=$matrix" >> $GITHUB_OUTPUT | |
| echo "matrix-linux=$matrix" | |
| echo ::endgroup:: | |
| # Set macOS matrix | |
| echo ::group::Set macOS matrix | |
| filename=".github/workflows/utils/full_matrix_macos.json" | |
| matrix=$(jq -c '[.[] | { "torch-version": .["torch-version"], "python-version": .["python-version"][], "cuda-version": .["cuda-version"][] }]' $filename) | |
| echo "matrix-macos=$matrix" >> $GITHUB_OUTPUT | |
| echo "matrix-macos=$matrix" | |
| echo ::endgroup:: | |
| # Set Windows matrix | |
| echo ::group::Set Windows matrix | |
| filename=".github/workflows/utils/full_matrix_windows.json" | |
| matrix=$(jq -c '[.[] | { "torch-version": .["torch-version"], "python-version": .["python-version"][], "cuda-version": .["cuda-version"][] }]' $filename) | |
| echo "matrix-windows=$matrix" >> $GITHUB_OUTPUT | |
| echo "matrix-windows=$matrix" | |
| echo ::endgroup:: | |
| linux: | |
| needs: [trigger] | |
| uses: ./.github/workflows/_build_linux.yml | |
| with: | |
| test-matrix: ${{ needs.trigger.outputs.matrix-linux }} | |
| release-type: ${{ inputs.release-type || 'nightly' }} | |
| docker-hub-username: ${{ vars.DOCKERHUB_USERNAME }} | |
| secrets: | |
| docker-hub-token: ${{ secrets.DOCKERHUB_TOKEN }} | |
| aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
| aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
| macos: | |
| needs: [trigger] | |
| uses: ./.github/workflows/_build_macos.yml | |
| with: | |
| test-matrix: ${{ needs.trigger.outputs.matrix-macos }} | |
| release-type: ${{ inputs.release-type || 'nightly' }} | |
| secrets: | |
| aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
| aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
| windows: | |
| needs: [trigger] | |
| uses: ./.github/workflows/_build_windows.yml | |
| with: | |
| test-matrix: ${{ needs.trigger.outputs.matrix-windows }} | |
| release-type: ${{ inputs.release-type || 'nightly' }} | |
| secrets: inherit | |
| index: | |
| if: ${{ always() && (inputs.release-type || 'nightly') == 'nightly' }} | |
| needs: [linux, macos, windows] | |
| uses: ./.github/workflows/_upload_index.yml | |
| with: | |
| release-type: ${{ inputs.release-type || 'nightly' }} | |
| secrets: inherit |