Closed ibalat closed 9 months ago
Voting 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 TF_LOG=DEBUG
output to be provided. The only parts that should be redacted are your user credentials in the X-Auth-Key
, X-Auth-Email
and Authorization
HTTP headers. Details such as zone or account identifiers are not considered sensitive but can be redacted if you are very cautious. This log file provides additional context from Terraform, the provider and the Cloudflare API that helps in debugging issues. Without it, maintainers are very limited in what they can do and may hamper diagnosis efforts.
This issue has been marked with triage/needs-information
and is unlikely to receive maintainer attention until the log file is provided making this a complete bug report.
this is not a provider issue but an issue with your loop logic not using a consistent list ordering via for_each
or dynamic
(an example of why we don't accept these as reproduction cases).
lists within terraform are not order dependent (nor are Go maps which back the terraform types) so for this to work, you need to need to introduce order dependency within your enumerations.
Confirmation
Terraform and Cloudflare provider version
Terraform v1.7.0 Cloudflare v4.23.0
Affected resource(s)
cloudflare_ruleset
Terraform configuration files
Link to debug output
https://gist.github.com/ibalat/260ab274ca121a23da0e858ae68e5c00
Panic output
No response
Expected output
I have prepared a ruleset list in the same order as on the cloudflare dashboard (r1, r2, r3...) and expect the rules must be created with same order like variable list order (
cloudflare_ruleset_custom_rules
). Becausecloudflare_ruleset
resource has not anypriority
ororder
field to create orderly. Why I need? Because the rule order effect traffic flow.Actual output
the rules randomly ordered (r2, r3, r1), not like variable list order (r1, r2, r3) (
cloudflare_ruleset_custom_rules
)Steps to reproduce
Additional factoids
No response
References
No response