sync #123
This file contains 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: sync | |
permissions: | |
contents: read | |
pull-requests: read | |
actions: read | |
defaults: | |
run: | |
shell: bash | |
on: | |
workflow_dispatch: | |
inputs: | |
max_releases: | |
description: "Maximum number of latest releases to sync" | |
required: false | |
default: 1 | |
type: number | |
specific_release_tag: | |
description: "Specific release tag to sync" | |
required: false | |
default: "" | |
type: string | |
dry_run: | |
description: "Skip the actual sync" | |
required: false | |
default: false | |
type: boolean | |
schedule: | |
- cron: "0 */12 * * *" # every 12 hours | |
jobs: | |
gitcode: | |
if: github.event_name == 'workflow_dispatch' | |
runs-on: ubuntu-22.04 | |
timeout-minutes: 240 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
persist-credentials: false | |
- name: Sync | |
uses: gpustack/.github/.github/actions/mirror-release-gitcode@main | |
with: | |
gitcode-username: "${{ secrets.CI_GITCODE_USERNAME }}" | |
gitcode-password: "${{ secrets.CI_GITCODE_PASSWORD }}" | |
gitcode-token: "${{ secrets.CI_GITCODE_TOKEN }}" | |
max-releases: "${{ inputs.max_releases && inputs.max_releases || '1' }}" | |
specific-release-tag: "${{ inputs.specific_release_tag && inputs.specific_release_tag || '' }}" | |
dry-run: "${{ inputs.dry_run && inputs.dry_run || 'false' }}" | |
gitee: | |
if: github.event_name == 'workflow_dispatch' | |
runs-on: ubuntu-22.04 | |
timeout-minutes: 120 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
persist-credentials: false | |
- name: Sync | |
uses: gpustack/.github/.github/actions/mirror-release-gitee@main | |
with: | |
gitee-username: "${{ secrets.CI_GITEE_USERNAME }}" | |
gitee-token: "${{ secrets.CI_GITEE_TOKEN }}" | |
max-releases: "${{ inputs.max_releases && inputs.max_releases || '1' }}" | |
specific-release-tag: "${{ inputs.specific_release_tag && inputs.specific_release_tag || '' }}" | |
dry-run: "${{ inputs.dry_run && inputs.dry_run || 'false' }}" | |
tencent-cos: | |
runs-on: ubuntu-22.04 | |
timeout-minutes: 120 | |
steps: | |
- name: Sync | |
uses: gpustack/.github/.github/actions/mirror-release-tencent-cos@main | |
with: | |
tencent-secret-id: "${{ secrets.CI_TECENTCOS_SECRET_ID }}" | |
tencent-secret-key: "${{ secrets.CI_TECENTCOS_SECRET_KEY }}" | |
tencent-cos-region: "ap-guangzhou" | |
tencent-cos-bucket: "gpustack-1303613262" | |
max-releases: "${{ inputs.max_releases && inputs.max_releases || '1' }}" | |
specific-release-tag: "${{ inputs.specific_release_tag && inputs.specific_release_tag || '' }}" | |
dry-run: "${{ inputs.dry_run && inputs.dry_run || 'false' }}" |