Add JSON validation to the aws_iam_policy resource (#10239)
Although the aws_iam_policy has a problem of normalization (refs #8350), I think it would be useful simply to add JSON syntax validation. I wasted a lot of time with JSON syntax errors. Validate the aws_iam_policy using the validateJsonString helper.
This commit is contained in:
parent
4caf7e082d
commit
f85e0b7249
|
@ -34,6 +34,7 @@ func resourceAwsIamPolicy() *schema.Resource {
|
|||
"policy": &schema.Schema{
|
||||
Type: schema.TypeString,
|
||||
Required: true,
|
||||
ValidateFunc: validateJsonString,
|
||||
},
|
||||
"name": &schema.Schema{
|
||||
Type: schema.TypeString,
|
||||
|
|
Loading…
Reference in New Issue