Skip to content

Commit d2cb4c7

Browse files
committed
Fix
1 parent ba3a232 commit d2cb4c7

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

.github/workflows/cloudflare-preview.yml

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,15 +15,13 @@ on:
1515
description: 'The repository to checkout (owner/repo)'
1616
required: true
1717
type: string
18-
# Reusable workflow doesn't have directly access to secrets, so we need to pass them in as inputs
18+
secrets:
1919
cloudflare_api_token:
2020
description: 'Cloudflare API Token'
2121
required: true
22-
type: string
2322
cloudflare_account_id:
2423
description: 'Cloudflare Account ID'
2524
required: true
26-
type: string
2725

2826
permissions:
2927
pull-requests: write # To allow commenting on the PR
@@ -52,8 +50,8 @@ jobs:
5250
id: deploy
5351
uses: cloudflare/wrangler-action@v3
5452
with:
55-
apiToken: ${{ inputs.cloudflare_api_token }}
56-
accountId: ${{ inputs.cloudflare_account_id }}
53+
apiToken: ${{ secrets.cloudflare_api_token }}
54+
accountId: ${{ secrets.cloudflare_account_id }}
5755
command: pages deploy ./_site --project-name=rdoc --branch="${{ inputs.pr_number }}-preview"
5856

5957
- name: Comment on PR with preview URL

.github/workflows/pr-preview-check.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ jobs:
1313
pr_number: ${{ github.event.pull_request.number }}
1414
pr_head_sha: ${{ github.event.pull_request.head.sha }}
1515
pr_checkout_repository: ${{ github.repository }}
16+
secrets:
1617
cloudflare_api_token: ${{ secrets.CLOUDFLARE_API_TOKEN }}
1718
cloudflare_account_id: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
1819

@@ -36,5 +37,6 @@ jobs:
3637
pr_number: ${{ github.event.pull_request.number }}
3738
pr_head_sha: ${{ github.event.pull_request.head.sha }}
3839
pr_checkout_repository: ${{ github.event.pull_request.head.repo.full_name }}
40+
secrets:
3941
cloudflare_api_token: ${{ secrets.CLOUDFLARE_API_TOKEN_FOR_FORKS }}
4042
cloudflare_account_id: ${{ secrets.CLOUDFLARE_ACCOUNT_ID_FOR_FORKS }}

0 commit comments

Comments
 (0)