-
Notifications
You must be signed in to change notification settings - Fork 630
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
pop_pools, region_pools, and country_pools do not remove when last block is removed #2659
Comments
Community NoteVoting for Prioritization
Volunteering to Work on This Issue
|
Thank you for reporting this issue! For maintainers to dig into issues it is required that all issues include the entirety of This issue has been marked with |
can you please provide the entirety of the debug output? i'm not seeing where the issue is here. |
Here's the full debug output, but there's a lot in there that isn't relevant. https://gist.github.com/troymjones/00ba9c87e5c1f9c260473d32ca6e1f18 The original gist above only shows the relevant portion. Did you see the example given as well as the expected output? To summarize - when a load balancer has pop_pools set, they correctly apply. Then on an update, when all the pop_pools blocks are removed, the terraform does not show any changes when it should in fact remove the pop_pools and show an update to the load balancer. Instead it shows no changes and the apply makes no updates. This is the same situation with country_pools and region_pools. |
This functionality has been released in v4.12.0 of the Terraform Cloudflare Provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading. For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template. Thank you! |
Confirmation
Terraform and Cloudflare provider version
Terraform v1.5.3
on darwin_arm64
Affected resource(s)
cloudflare_load_balancer
Terraform configuration files
Link to debug output
Relevant output: https://gist.github.com/troymjones/815f8f633abf9296c949dc5dc254803b
Full output: https://gist.github.com/troymjones/00ba9c87e5c1f9c260473d32ca6e1f18
Panic output
No response
Expected output
Actual output
Steps to reproduce
Additional factoids
This seems to be an issue with the fact the key does not exist and therefore the blank/null value is never set. See code here: https://github.com/cloudflare/terraform-provider-cloudflare/blob/master/internal/sdkv2provider/resource_cloudflare_load_balancer.go#L184-L190
Datadog has a similar provider with assertions under datadog_synthetics_test resource. By setting it as an empty object before checking for the key, it gets set to a blank value if the key does not exist. See code here: https://github.com/DataDog/terraform-provider-datadog/blob/master/datadog/resource_datadog_synthetics_test_.go#L1458
References
No response
The text was updated successfully, but these errors were encountered: