Skip to content

Conversation

@raulk
Copy link
Contributor

@raulk raulk commented Jan 4, 2026

Summary

  • Adds worker deployment step to CI using cloudflare/wrangler-action@v3
  • Deploys when worker files change on push to main
  • Manual workflow dispatch always deploys worker

Problem

The worker caching fix from commit 1d09fa3 was never deployed. The CI only uploads site content to R2, not the worker itself. This caused HTML pages to be served with aggressive caching (max-age=31536000, immutable) instead of the correct headers (max-age=0, must-revalidate).

Test plan

  • Add WORKERS_API_TOKEN secret to repo
  • Merge and trigger workflow dispatch to deploy worker
  • Verify HTML responses have correct cache headers

The worker caching fix from commit 1d09fa3 was never deployed because
the CI workflow only uploads site content to R2, not the worker itself.

This adds a step to deploy the worker when:
- Worker files change on push to main
- Manual workflow dispatch (always deploys)

Requires WORKERS_API_TOKEN secret to be set.
@raulk raulk force-pushed the fix/deploy-worker-in-ci branch from 02b2c04 to 35396dd Compare January 4, 2026 17:33
@raulk raulk merged commit e3d89bc into main Jan 4, 2026
1 check failed
@github-actions
Copy link

github-actions bot commented Jan 4, 2026

Preview Deployment

🚀 Preview is ready!

URL: https://observatory-staging.ethp2p.dev/pr-32/

Updated: 2026-01-04T17:42:21.526Z

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants