signalsciences / terraform-provider-sigsci

Signal sciences terraform provider
MIT License
26 stars 30 forks source link

Adding support for Client IP Rules #205

Closed aaronmaxlevy closed 5 months ago

aaronmaxlevy commented 9 months ago

Adding support for Client IP Rules, as this is configurable from the web UI / dashboard, but isn't currently manageable via Terraform.

daniel-corbett commented 5 months ago

Hi @aaronmaxlevy - apologies for the delay here. Thanks for putting this together. Overall, it looks good to me. I would like to change this from a TypeSet to a TypeList - mostly because a TypeSet is for an "unordered collection of items" where as TypeList is documented as an ordered collection of items.

The reason for this suggested change is the documentation for the client IP headers says the following:

Headers will be used in order from top to bottom, meaning if the first header is not present in the request, the agent will proceed to check for the second header, and so on, until one of the listed headers is found.

So a user could want to control the order here.

I have staged a change locally and I can push it up to this branch but just wanted to check if you had any concerns with that switch.

aaronmaxlevy commented 5 months ago

Thanks @daniel-corbett I am 100% on board with that change — go for it!

Thanks, Aaron

daniel-corbett commented 5 months ago

Hi @aaronmaxlevy - thanks again for your contribution! This is now available in version 3.0.1. If you have not upgraded to 3.x yet please keep in mind it is a breaking change. We have a detailed guide here - please read it thoroughly:

https://registry.terraform.io/providers/signalsciences/sigsci/latest/docs/guides/3.0.0

aaronmaxlevy commented 5 months ago

No problem! Thanks for the help and heads up!