You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We can also not use the opts=pulumi.ResourceOptions(provider=myprovider) method to select the provider (it misses the "package" attribute) and we are required to give the provider in the __init__ of the resource. Hopefully I can add a provider parameter to it.
This is not so much of a burden when we can hardcode the provider instantiation in the resource, but when we have multiple resources for multiple providers, this becomes a real pain.
I am wondering why this was made this way and how I could re-use a single provider definition? Can someone explain this and/or provide an alternative to this ?
I see there are some serialization with pickle, so I cannot even send callbacks (or not easily).
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi,
I am trying to follow Dynamic resource providers.
I want to define 1 provider that knows the credentials, and multiple resources for this provider.
The current way forces me to create 1 Provider per resource:
When I expected something like:
We can also not use the
opts=pulumi.ResourceOptions(provider=myprovider)
method to select the provider (it misses the "package" attribute) and we are required to give the provider in the__init__
of the resource. Hopefully I can add aprovider
parameter to it.This is not so much of a burden when we can hardcode the provider instantiation in the resource, but when we have multiple resources for multiple providers, this becomes a real pain.
I am wondering why this was made this way and how I could re-use a single provider definition? Can someone explain this and/or provide an alternative to this ?
I see there are some serialization with pickle, so I cannot even send callbacks (or not easily).
Beta Was this translation helpful? Give feedback.
All reactions