62 lines
1.5 KiB
YAML
62 lines
1.5 KiB
YAML
name: Sync assets with release
|
|
|
|
on:
|
|
workflow_call:
|
|
inputs:
|
|
CONCURRENCY:
|
|
required: true
|
|
type: string
|
|
RELEASE_VERSION:
|
|
required: true
|
|
type: string
|
|
default: ""
|
|
WAIT_TIME_SECS:
|
|
required: false
|
|
type: number
|
|
default: 0
|
|
|
|
concurrency:
|
|
group: ${{ inputs.CONCURRENCY }}-sync-assets
|
|
cancel-in-progress: true
|
|
|
|
defaults:
|
|
run:
|
|
shell: bash --noprofile --norc -euo pipefail {0}
|
|
|
|
permissions:
|
|
contents: "write"
|
|
id-token: "write"
|
|
|
|
jobs:
|
|
sync-assets:
|
|
name: Upload assets from build.rerun.io
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v4
|
|
with:
|
|
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.ref || '' }}
|
|
|
|
- uses: prefix-dev/setup-pixi@v0.10.0
|
|
with:
|
|
pixi-version: v0.71.3
|
|
|
|
- id: "auth"
|
|
uses: google-github-actions/auth@v2
|
|
with:
|
|
workload_identity_provider: ${{ secrets.GOOGLE_WORKLOAD_IDENTITY_PROVIDER }}
|
|
service_account: ${{ secrets.GOOGLE_SERVICE_ACCOUNT }}
|
|
|
|
- name: "Set up Cloud SDK"
|
|
uses: "google-github-actions/setup-gcloud@v2"
|
|
with:
|
|
version: ">= 363.0.0"
|
|
|
|
- name: Sync release assets & build.rerun.io
|
|
run: |
|
|
pixi run python ./scripts/ci/sync_release_assets.py \
|
|
--github-release ${{ inputs.RELEASE_VERSION }} \
|
|
--github-token ${{ secrets.GITHUB_TOKEN }} \
|
|
--wait ${{ inputs.WAIT_TIME_SECS }} \
|
|
--remove --update
|