Search code examples
terraformterraform-provider-awsamazon-waf

Is there a way to create a WAFv2 from a Terraform script


I managed to build a WAF(v1) infrastructure component on AWS using a Terraform script. Since November 2019, AWS recommends to use a WAFv2 instead, but I don't see how to script this one using Terraform.


Solution

  • This is not supported by terraform yet. However, if you really want to use terraform, I have built a module which uses cloudformation resource to deploy wafv2. You can find it -> https://github.com/umotif-public/terraform-aws-waf-webaclv2

    It is published to terraform registry so you can source it from there.