Files
gitea-github-cron/.github/workflows/mirror.yml
T
multipleof4andClaude Opus 5.5 474b475f18 Sync descriptions and issues, run workflows nightly
mirror.js now keeps repo descriptions in step with GitHub. A new
sync-issues workflow copies issues, PR conversations and comments onto
the mirrors with GitHub's numbering. Shared API helpers move to
gitea-mirrors.js. Every workflow now runs once a night, 1.5 hours apart.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 17:37:50 +00:00

43 lines
1.1 KiB
YAML

name: Mirror to Gitea
on:
workflow_dispatch:
inputs:
notification_test:
description: Send a test notification without running the mirror
type: boolean
default: false
schedule:
- cron: '0 5 * * *' # 12 AM CDT
jobs:
mirror:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 20
- name: Run Mirror Script
id: sync
if: ${{ !inputs.notification_test }}
run: node mirror.js
env:
GH_PAT: ${{ secrets.GH_PAT }}
GITEA_TOKEN: ${{ secrets.GITEA_TOKEN }}
GITEA_URL: ${{ secrets.GITEA_URL }}
- name: Notify via ntfy
if: ${{ always() }}
run: node notify.js
env:
NTFY_TOPIC_URL: ${{ secrets.NTFY_TOPIC_URL }}
WORKFLOW_KIND: mirror
STEP_OUTCOME: ${{ steps.sync.outcome }}
TEST_NOTIFICATION: ${{ inputs.notification_test }}
RUN_URL: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}