Skip to content
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

Confusing error message about subscription_id #2497

Open
mikhailshilkov opened this issue Sep 30, 2024 · 3 comments
Open

Confusing error message about subscription_id #2497

mikhailshilkov opened this issue Sep 30, 2024 · 3 comments
Labels
area/docs Improvements or additions to documentation help-wanted We'd love your contributions on this issue kind/bug Some behavior is incorrect or out of spec

Comments

@mikhailshilkov
Copy link
Member

Describe what happened

6.x versions of the provider now require setting an explicit subscriptionId configuration. However, if I don't set it, I get the following error

error: 1 error occurred:
    	* `subscription_id` is a required provider property when performing a plan/apply operation

Notice that this is likely a Terraform error:

  • subscription_id is not the correct name of the parameter
  • plan/apply operation are not the terms Pulumi uses

Please change the error message to be Pulumi-specific. It seems important given the potential number of users that hit this during upgrades.

Sample program

Any Azure Classic program with 6.0 or later

Log output

No response

Affected Resource(s)

No response

Output of pulumi about

pulumi-azure 6.2.0

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).

@mikhailshilkov mikhailshilkov added kind/bug Some behavior is incorrect or out of spec needs-triage Needs attention from the triage team labels Sep 30, 2024
@danielrbradley danielrbradley added area/docs Improvements or additions to documentation help-wanted We'd love your contributions on this issue and removed needs-triage Needs attention from the triage team labels Sep 30, 2024
@danielrbradley
Copy link
Member

Yup, makes sense 👍

@kraakevik
Copy link

kraakevik commented Oct 3, 2024

Is this a bug in terms of what the default provider is passing down to TF, or am I now required to either create a custom provider or set the config option azure:subscriptionId?

Method 1:

const subscriptionId = azure.authorization.getClientConfigOutput().subscriptionId
let azureClassicProvider = new azure_classic.Provider("Azure classic provider", {subscriptionId: subscriptionId})

Method 2:

config:
  azure:subscriptionId: 00000000-0000-0000-0000-0000000000

Since everything else is inferred from the current context, I feel like the subscriptionId should also be passed down by default? Am I missing something?

@mikhailshilkov
Copy link
Member Author

@kraakevik I believe this is by design: https://www.pulumi.com/registry/packages/azure/v6-migration/#subscription-id-is-now-mandatory

@mjeffryes mjeffryes added this to the 0.112 milestone Oct 30, 2024
@mjeffryes mjeffryes removed this from the 0.112 milestone Nov 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/docs Improvements or additions to documentation help-wanted We'd love your contributions on this issue kind/bug Some behavior is incorrect or out of spec
Projects
None yet
Development

No branches or pull requests

4 participants