Add clear steps for adding Cloudflare credentials and completing the Pages deployment. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2 KiB
2 KiB
Cloudflare Pages Deployment - Next Steps
The deployment infrastructure is configured and ready. To complete the deployment, follow these steps:
Quick Start (Recommended)
1. Get Your Cloudflare Credentials
API Token:
- Go to Cloudflare API Tokens
- Create a token with Edit Cloudflare Workers permissions
- Copy the token
Account ID:
- Go to any Cloudflare page in the dashboard
- Find your Account ID in the right sidebar
- Or run:
wrangler whoamiafter logging in
2. Add Secrets to GitHub
- Go to your repository: https://github.com/jedarden/ai-code-battle/settings/secrets/actions
- Click New repository secret
- Add
CLOUDFLARE_API_TOKENwith your API token - Add
CLOUDFLARE_ACCOUNT_IDwith your account ID
3. Trigger Deployment
The workflow will automatically run on the next push to master, or you can trigger it manually:
gh workflow run deploy-pages.yml
Or via the GitHub UI: https://github.com/jedarden/ai-code-battle/actions/workflows/deploy-pages.yml
Manual Deployment with Wrangler
If you prefer to deploy locally:
# Install wrangler (if not already installed)
npm install -g wrangler
# Login to Cloudflare
wrangler login
# Deploy
cd /home/coding/ai-code-battle
./scripts/deploy-pages.sh
What's Already Done
✓ Build configured (web/package.json, vite.config.ts)
✓ GitHub Actions workflow configured (.github/workflows/deploy-pages.yml)
✓ Wrangler configuration (wrangler.toml)
✓ Deployment script (scripts/deploy-pages.sh)
✓ Documentation (web/CLOUDFLARE_DEPLOYMENT.md)
✓ Build tested and working (web/dist)
After Deployment
Once deployed, the site will be accessible at:
- Pages URL: https://ai-code-battle.pages.dev
- Custom domain: https://aicodebattle.com (if configured in Cloudflare)
Verification
# Check deployment status
gh run list --workflow=deploy-pages.yml
# View the live site
curl https://ai-code-battle.pages.dev