red-salesclerk-85731
02/27/2020, 7:08 PM"list_policy": {
(...)
"allow": {
(...)
"all": {
Type: schema.TypeBool,
Optional: true,
############ ---> Default: false, <-- Default Value #########
ExactlyOneOf: []string{"list_policy.0.allow.0.all", "list_policy.0.allow.0.values"},
},
"values": {
Type: schema.TypeSet,
Optional: true,
ExactlyOneOf: []string{"list_policy.0.allow.0.all", "list_policy.0.allow.0.values"},
Elem: &schema.Schema{Type: schema.TypeString},
Set: schema.HashString,
},
},
},
},
https://github.com/terraform-providers/terraform-provider-google/blob/1f9e0cb9c3cef1c65cfd2054ca8dfd2795ac42a6/google/resource_google_organization_policy.go#L55
And I created it like this:
new projects.OrganizationPolicy('Only allow resource in Europe', {
constraint: 'gcp.resourceLocations',
project: gcloud.project,
listPolicy: {
allow: {
values: ['in:europe-west4-locations']
}
}
})
What would be the value of resource.listPolicy.allow.all
?red-salesclerk-85731
02/27/2020, 7:09 PMwhite-balloon-205
white-balloon-205
red-salesclerk-85731
02/27/2020, 8:47 PMred-salesclerk-85731
02/27/2020, 8:48 PMred-salesclerk-85731
02/27/2020, 8:51 PMwhite-balloon-205
Is there a general guide on how to debug the output Pulumi send to terraform?See https://www.pulumi.com/docs/troubleshooting/#verbose-logging for verbose logs which will include the values marshalled to and from all provider calls. But if the bug is what we are assuming here - I expect this will show that the default is being applied earlier that Terraform would apply it, and thus triggering the ExactlyOneOf.
red-salesclerk-85731
02/28/2020, 12:33 PMred-salesclerk-85731
02/28/2020, 1:49 PM