Open DMeechan opened 1 week ago
Hi.
Thank you for reporting this. Unfortunately terraform-plugin-docs doesn't have support for this at the moment.
However, it's also an oversight on my part that there was no validation for the triggers. I've added it via cd530252329dd95d8fb693f947fdb78170b5a196, alongside with some tests to avoid regressions.
│ Error: Trigger type must be valid
│
│ with bunnynet_pullzone_edgerule.block_admin,
│ on issue-17.tf line 21, in resource "bunnynet_pullzone_edgerule" "block_admin":
│ 21: triggers = [
│ 22: {
│ 23: type = "invalid"
│ 24: match_type = "MatchAny"
│ 25: patterns = ["*"]
│ 26: parameter1 = null
│ 27: parameter2 = null
│ 28: }
│ 29: ]
│
│ Trigger "type" must be one of
│ ["ResponseHeader","CountryCode","RemoteIP","RandomChance","StatusCode","CookieValue","Url","RequestHeader","UrlExtension","UrlQueryString","RequestMethod","CountryStateCode"].
I'll keep this issue open until we have upstream support, or at least some workaround implemented.
Thank you.
Hi! Could you add the different values for
bunnynet_pullzone_edgerule.triggers.type
to the Terraform docs please?I was getting this
panic: value not found in map
error:Cause:
Turns out I was using an invalid value for the trigger type. I found the correct value in the source code (in my case I needed
UrlQueryString
)Thanks!