-
Notifications
You must be signed in to change notification settings - Fork 9.3k
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
[aws_wafv2_web_acl] WAFInvalidParameterException after import of Web ACL #14029
Comments
Hmmmm ... I guess you must have the...
...block present in the |
This! I kept getting the same error except it was complaining about From https://docs.aws.amazon.com/waf/latest/APIReference/API_Rule.html:
|
A fix has been merged and will release with |
This has been released in version 3.2.0 of the Terraform AWS provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading. For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template for triage. Thanks! |
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks! |
Description
Running
terraform apply
of aaws_wafv2_web_acl
that was imported usingterraform import
throws an error because of an invalid configuration.Community Note
Terraform Version
Affected Resource(s)
Terraform Configuration Files
waf.tf
Debug Output
Trace output: https://gist.github.com/sc250024/00e7b574459e3ee5bc930cde663dc099
Note that I previously run a
terraform plan -out ...
command, and then ran theapply
command. The above Gist is from theapply
of the plan file.Panic Output
N/A
Expected Behavior
Terraform should not complain about changing a resource it has imported. All of the
rule
blocks, as well as thedefault_action
and rootvisibility_config
blocks all came from the import.Actual Behavior
Terraform runs a
terraform plan
fine, but when theapply
stage comes, the following error is shown on the console:Steps to Reproduce
Run a
terraform import
of the Web ACL resource created above.Run a
terraform state show aws_wafv2_web_acl.common
of the resource to get therules
blocks, and put it in the main definition ofaws_wafv2_web_acl
.Change something about the
aws_wafv2_web_acl
, like thedescription
field, and run aterraform apply
.Observe the
400
error mentioned above.Important Factoids
I am running a
terraform import
because I typically do this to avoid having to manually type complicated Terraform code, such as the one created byaws_wafv2_web_acl
in this case.The text was updated successfully, but these errors were encountered: