Open zbuchheit opened 4 months ago
Hey @zbuchheit, the example you quoted looks like it's not in Go. Did you activate the "Go" tab under "Example Usage"?
The Go example in the docs is
Identity: &dbforpostgresql.UserAssignedIdentityArgs{
Type: pulumi.String(dbforpostgresql.IdentityTypeUserAssigned),
UserAssignedIdentities: dbforpostgresql.UserIdentityMap{
"/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testresourcegroup/providers/Microsoft.ManagedIdentity/userAssignedIdentities/test-usermanagedidentity": nil,
},
},
This seems identical to your working code, except that you need an apply
to access userAssignedIdentity.ID()
.
I'm not sure why you need the .(dbforpostgresql.UserIdentityMapOutput)
at the end.
Whoops, sorry was multitasking and accidentally copied over the typescript example, I updated the issue. I believe the difference lies here with id: dbforpostgresql.UserIdentityArgs{}
, vs id: nil,
. When I tried nil
it wasn't working as desired.
@danielrbradley Do you know why this resource still has the old weird structure of userAssignedIdentities and wasn't improved in https://github.com/pulumi/pulumi-azure-native/pull/1833?
@mikhailshilkov it looks like a mistake in the specs for this resource where the client id and principle id are marked as inputtable by the user, so we honnor this and generate an input type for the fields and don't flattern the map into a string set.
What happened?
When attempting to user a UserAssignedIdentity with
dbforpostgresql.Server
in Golang here, a user ran into issues and wasn't able to get the example from ServerCreatewithDataEncryptionEnabled to work properly.Example
This example from the documentation doesn't work as intended
while this is what I was able get to work for the user
Output of
pulumi about
Additional context
No response
Contributing
Vote on this issue by adding a 👍 reaction. To contribute a fix for this issue, leave a comment (and link to your pull request, if you've opened one already).