Conversation
There was a problem hiding this comment.
Pull request overview
This PR adds GitHub Actions deployment automation to enable continuous deployment of the Cloudflare Worker to production on pushes to the main branch. It also updates documentation to clarify the TOKEN secret setup for direct deployments.
Changes:
- Added GitHub Actions workflow for automatic deployment to Cloudflare Workers
- Updated README to clarify TOKEN setup instructions for direct Cloudflare deployment
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| .github/workflows/deploy.yml | New GitHub Actions workflow that deploys to Cloudflare Workers on main branch pushes |
| README.md | Updated deployment instructions with clarification about setting TOKEN in Cloudflare Dashboard |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| 4. Deploy the worker with `npm run deploy` | ||
|
|
||
| Or deploy directly to Cloudflare | ||
| Or deploy directly to Cloudflare and set TOKEN from your Cloudflare Dashboad. |
There was a problem hiding this comment.
Corrected spelling of 'Dashboad' to 'Dashboard'.
| with: | ||
| apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} | ||
| secrets: | | ||
| TOKEN No newline at end of file |
There was a problem hiding this comment.
The secrets field expects key-value pairs but only the key 'TOKEN' is provided without a value. To pass the TOKEN secret to Wrangler, you need to provide the actual secret value from GitHub Secrets, for example: 'TOKEN=${{ secrets.TOKEN }}' or use the 'secretsJson' parameter instead if the secret should be retrieved from Cloudflare's environment.
| TOKEN | |
| TOKEN=${{ secrets.TOKEN }} |
Add deploy action to make the "Deploy with Workers" work!