Skip to content

Scheduled Polling #13753

Scheduled Polling

Scheduled Polling #13753

Workflow file for this run

name: Scheduled Polling
on:
schedule:
- cron: "*/30 * * * *"
push:
paths:
- 'fetch/workflow_template.yaml'
workflow_dispatch:
inputs:
origin:
description: 'The entity that dispatches this event'
required: false
type: string
teams:
description: 'Comma-separated numeric team IDs to update. Default to empty, meaning updating all teams.'
required: false
type: string
concurrency:
group: polling
cancel-in-progress: true
jobs:
fetch-update:
name: Fetch updates
environment: Polling
runs-on: ubuntu-latest
steps:
- name: Log initiator
shell: bash
run: |
echo ::notice::This polling is started by ${{ inputs.origin }} on behalf of ${{ github.triggering_actor }}
- name: Checkout
uses: actions/checkout@v4
- name: Auth as Github App
id: auth-as-github-app
shell: bash
env:
APP_ID: ${{ secrets.APP_ID }}
APP_PRIVATE_KEY: ${{ secrets.APP_PRIVATE_KEY }}
run: bash fetch/auth.sh
- name: Re-Checkout
uses: actions/checkout@v4
with:
token: ${{ steps.auth-as-github-app.outputs.token }}
- name: Setup Python3
uses: actions/setup-python@v5
with:
python-version: '3.11'
architecture: 'x64'
- name: Query Updates
shell: bash
env:
GITHUB_TOKEN: ${{ steps.auth-as-github-app.outputs.token }}
BILUOCHUN_TOKEN: ${{ secrets.BILUOCHUN_TOKEN }}
run: python3 fetch/query.py ${{ inputs.teams }}
- name: Commit Changes
shell: bash
run: |
source fetch/commit_info.sh
git add .github/workflows
git commit -m "`date -u`: create/update new build workflow(s)" || true
git add mods
git commit -m "`date -u`: trigger new build(s)" || true
git push