-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
Improve DX for Cloudflare Worker Enviroments #15917
Copy link
Copy link
Closed as not planned
Labels
- P2: has workaroundAn edge case that only affects very specific usage, but has a trivial workaround (priority)An edge case that only affects very specific usage, but has a trivial workaround (priority)ecosystem: upstreamUpstream package has issueUpstream package has issuepkg: cloudflareRelated to the Cloudflare adapterRelated to the Cloudflare adapter
Description
Metadata
Metadata
Assignees
Labels
- P2: has workaroundAn edge case that only affects very specific usage, but has a trivial workaround (priority)An edge case that only affects very specific usage, but has a trivial workaround (priority)ecosystem: upstreamUpstream package has issueUpstream package has issuepkg: cloudflareRelated to the Cloudflare adapterRelated to the Cloudflare adapter
Type
Fields
Give feedbackNo fields configured for issues without a type.
Astro Info
If this issue only occurs in one browser, which browser is a problem?
n/a
Describe the Bug
Astro v6's Cloudflare adapter doesn't support environments and drops all environment specific settings.
In my project, I have a dev, staging, and prod environment. Each one has a unique route and KV store to back it. When I deploy, only the global values are being used even when I specify the environment. For example, I run
pnpm wrangler deploy --env staging. I noticed that the generated wrangler.json file in dist/server/ doesn't include any of the environment settings from the original wrangler.jsonc file. It also has definedEnvironments so the deploy doesn't fail when running the deploy. This could cause accidental deployments depending on the setup.What's the expected result?
I should be able to specify unique cloudflare environments and have them use unique URLs, etc....
Link to Minimal Reproducible Example
https://github.com/asdfjkalsdfla/astro-callous-chroma
Participation