I am trying to instantiate an azure-native.Provide...
# general
p
I am trying to instantiate an azure-native.Provider with OIDC from my code. We are using multiple providers in a project, which means that we can't use the OIDC environment variables as shown here. However, it seems like the ProviderArgs don't support any OIDC configuration inputs? The former azure.Provider still supported a whole bunch of OIDC inputs, like the
oidcToken
. Is this not supported in the azure-native.Provider anymore? Can we only create an OIDC-enabled provider via the environment variables, not through code? I'm looking for something along those lines:
Copy code
const customProvider = new azure_native.Provider("customProvider", {
    oidcToken: ...
});
f
Hey @prehistoric-school-19136! I am checking in with the team regarding feedback on this topic. In the meantime, if your concern is mainly around configuring/maintaining environment variables locally, then this may be a great use case for implementing Pulumi ESC. We have some helpful content around: • Configuring OIDC with Azure and • Projecting Environment Variables in Pulumi ESC You can configure your environment so that those OIDC environment variables are dynamically generated and consumed when you run
pulumi up
p
Thank you @fierce-night-38522, ESC is part of Pulumi cloud, right? Unfortunately, we can't use that at the moment. The problem with the environment variables is that I need to configure two Azure native providers at the same time, both with different OIDC credentials, which means that I can't use the environment variables to configure the providers (both providers would use the same credentials, which I can't use). I hope that makes sense
m
Thank you for reporting this! I believe this was an oversight. I’ve raised issue https://github.com/pulumi/pulumi-azure-native/issues/2873 and started working on the fix.
p
awesome, thank you! I would've raised an issue myself but I wasn't sure if it was intentional and I'd missed something