-
Notifications
You must be signed in to change notification settings - Fork 14
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
Error when trying to create a Type of Object or map or list in Terraform #32
Comments
If you register a custom version of ISchemaBuilder it should work
I should probably get a PR raised... |
Object types are now supported (535e246). Please see this example: TerraformPluginDotNet/TerraformPluginDotNet.Test/TestResource.cs Lines 65 to 68 in 535e246
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hello,
I want to create a terraform resource that have an attribute as object type.
In C#, I create an IDictionary<string, object> but when execute the Terraform plan I got this error below:
System.NotSupportedException: Unable to convert System.Collections.Generic.KeyValuePair`2[[System.String, System.Private.CoreLib, Version=7.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Object, System.Private.CoreLib, Version=7.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]] to Terraform type.
Any idea how to create an object in terraform using the C# plugin ?
ex.:
resource "demo_player" "player" {
name = ""
player = {
name = ""
streams = ""
}
}
THank you
The text was updated successfully, but these errors were encountered: