mirror of
https://github.com/homarr-labs/dashboard-icons.git
synced 2026-01-12 16:25:38 +08:00
1.3 KiB
1.3 KiB
Add Icon Workflow Usage
This repository exposes .github/workflows/add-icon.yml to import an accepted PocketBase submission into the collection, commit assets/metadata, and mark the submission as added_to_collection.
Required secrets
PB_URL: PocketBase base URL (e.g.,https://pb.example.com).PB_ADMIN_TOKEN: PocketBase superuser/impersonation token with permission to read submissions and update their status.
Inputs
submissionId(string, required): PocketBase submission record ID.dryRun(boolean, optional, defaultfalse): Skip writes, commit, and status update.
Trigger via GitHub API (backend/webhook)
Use a token with workflow scope:
curl -X POST \
-H "Authorization: Bearer $GITHUB_TOKEN" \
-H "Accept: application/vnd.github+json" \
https://api.github.com/repos/<OWNER>/<REPO>/actions/workflows/add-icon.yml/dispatches \
-d '{
"ref": "main",
"inputs": {
"submissionId": "SUBMISSION_RECORD_ID",
"dryRun": "false"
}
}'
Trigger from another workflow
jobs:
add-icon:
uses: ./.github/workflows/add-icon.yml
with:
submissionId: ${{ github.event.inputs.submissionId }}
dryRun: false
secrets:
PB_URL: ${{ secrets.PB_URL }}
PB_ADMIN_TOKEN: ${{ secrets.PB_ADMIN_TOKEN }}