Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wrangler deletes environment variables set by Terraform configuration on deployment of Pages project #7642

Open
alex35mil opened this issue Dec 30, 2024 · 1 comment
Labels
awaiting reporter response Needs clarification or followup from OP enhancement New feature or request

Comments

@alex35mil
Copy link

Describe the solution

When managing infrastructure with Terraform and deploying Pages project with Wrangler, the latter messes up configuration set by the former.

For example, I set env vars in pages project via Terraform config and then build/deploy code using Wrangler CLI. On deployment, Wrangler deletes all env vars set by the Terraform (except for the secrets). keep_vars/--keep-vars is not available for Pages deployment.

@alex35mil alex35mil added the enhancement New feature or request label Dec 30, 2024
@github-project-automation github-project-automation bot moved this to Untriaged in workers-sdk Dec 30, 2024
@CarmenPopoviciu
Copy link
Contributor

hi @alex35mil,

does your Pages project have a wrangler.toml configuration file? If it does that would explain why your env vars get overriden, as there can only be one config source of truth.

@CarmenPopoviciu CarmenPopoviciu added the awaiting reporter response Needs clarification or followup from OP label Jan 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
awaiting reporter response Needs clarification or followup from OP enhancement New feature or request
Projects
Status: Untriaged
Development

No branches or pull requests

2 participants