mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-04-25 00:39:49 +00:00
- og.ts: use SatoriNode type instead of unknown for satori() param - Pin all GitHub Action refs to commit SHAs (validate-pins) - Add vercel to knip ignoreBinaries (hub-preview-cron uses npx vercel)
69 lines
2.1 KiB
YAML
69 lines
2.1 KiB
YAML
name: Hub Cron Rebuild
|
|
|
|
on:
|
|
schedule:
|
|
# Every 15 minutes — rebuilds the site to pick up new UGC workflows
|
|
# for search index, sitemap, filter pages, and pre-rendered detail pages.
|
|
- cron: '*/15 * * * *'
|
|
workflow_dispatch:
|
|
|
|
concurrency:
|
|
group: hub-deploy-prod
|
|
cancel-in-progress: false
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
jobs:
|
|
rebuild:
|
|
runs-on: ubuntu-latest
|
|
env:
|
|
SKIP_AI_GENERATION: 'true'
|
|
PUBLIC_POSTHOG_KEY: ${{ secrets.HUB_POSTHOG_KEY }}
|
|
PUBLIC_GA_MEASUREMENT_ID: ${{ secrets.HUB_GA_MEASUREMENT_ID }}
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v6
|
|
|
|
- name: Setup frontend
|
|
uses: ./.github/actions/setup-frontend
|
|
|
|
- name: Checkout templates data
|
|
uses: actions/checkout@v6
|
|
with:
|
|
repository: Comfy-Org/workflow_templates
|
|
path: _workflow_templates
|
|
sparse-checkout: templates
|
|
token: ${{ secrets.GH_TOKEN }}
|
|
|
|
- name: Restore content cache
|
|
uses: actions/cache@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0
|
|
with:
|
|
path: apps/hub/.content-cache
|
|
key: hub-content-cache-cron-prod-${{ hashFiles('_workflow_templates/templates/**', 'apps/hub/src/**') }}
|
|
restore-keys: |
|
|
hub-content-cache-cron-prod-
|
|
|
|
- name: Sync templates
|
|
run: pnpm run sync
|
|
working-directory: apps/hub
|
|
env:
|
|
HUB_TEMPLATES_DIR: ${{ github.workspace }}/_workflow_templates/templates
|
|
|
|
- name: Build Astro site
|
|
run: pnpm run build
|
|
working-directory: apps/hub
|
|
env:
|
|
PUBLIC_HUB_API_URL: ${{ secrets.HUB_API_URL_PRODUCTION }}
|
|
PUBLIC_COMFY_CLOUD_URL: ${{ secrets.COMFY_CLOUD_URL_PRODUCTION }}
|
|
PUBLIC_APPROVED_ONLY: 'true'
|
|
|
|
- name: Deploy to Vercel
|
|
uses: amondnet/vercel-action@16e87c0a08142b0d0d33b76aeaf20823c381b9b9 # v25.2.0
|
|
with:
|
|
vercel-token: ${{ secrets.VERCEL_TOKEN }}
|
|
vercel-org-id: ${{ secrets.VERCEL_ORG_ID }}
|
|
vercel-project-id: ${{ secrets.HUB_VERCEL_PROJECT_ID }}
|
|
working-directory: apps/hub
|
|
vercel-args: '--prebuilt --prod'
|