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

Allow zone_id to set zone and vice versa #174

Merged

Conversation

jacobbednarz
Copy link
Member

During an import of the cloudflare_firewall_rule resource, the zone_id is
defined within the composite ID. This value is then populated and synced
within resourceCloudflareFirewallRuleRead to match the expected schema
resource. However, we don't currently set zone (the zone name)
anywhere. This becomes problematic on subsequent terraform operations as
the Read attempts to sync the schema with the firewall rule and ends up
attempting to recreate the resource due to detecting a change.

This is a similar issue to #161 and is addressed in a similar manner.

Fixes #165

During an import of the `cloudflare_firewall_rule` resource, the `zone_id` is
defined within the composite ID. This value is then populated and synced
within `resourceCloudflareFirewallRuleRead` to match the expected schema
resource. However, we don't currently set zone (the zone name)
anywhere. This becomes problematic on subsequent terraform operations as
the Read attempts to sync the schema with the firewall rule and ends up
attempting to recreate the resource due to detecting a change.

This is a similar issue to cloudflare#161 and is addressed in a similar manner.

Fixes cloudflare#165
@patryk
Copy link
Contributor

patryk commented Dec 5, 2018

Yup, you're right. Thanks!

@patryk patryk merged commit 0afb203 into cloudflare:master Dec 5, 2018
@jacobbednarz jacobbednarz deleted the ensure-zone-set-for-firewall-rule branch December 5, 2018 02:09
@jamfish jamfish mentioned this pull request Apr 16, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants