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

Fix Subscription Api error #726

Merged

Conversation

msalemcode
Copy link
Contributor

Description

This PR addresses a critical issue in the deployment script (Deploy.ps1) where an API call is made to check if a KeyVault (KV) exists before the subscriptionID is properly assigned. This premature API call results in an error due to the lack of a valid subscriptionID. The error message encountered is as follows:
ERROR: Bad Request({"error":{"code":"InvalidSubscriptionId","message":"The provided subscription identifier 'providers' is malformed or invalid."}})

Changes Made

  • Modified the Deploy.ps1 script to ensure that the subscriptionID is assigned before any API calls are made. This change prevents the aforementioned error by ensuring that a valid subscriptionID is available for the API call that checks for the existence of a KeyVault.

Impact

  • This change fixes the deployment failure issue by correcting the order of operations in the script. By setting the subscriptionID before making the API call, we avoid the InvalidSubscriptionId error and ensure a smoother deployment process.

Testing

  • The updated script has been tested to confirm that the subscriptionID is correctly assigned before the API call is made. This ensures that the deployment process proceeds without encountering the InvalidSubscriptionId error.

Conclusion

This PR resolves a critical bug in the deployment process by adjusting the sequence of operations in the Deploy.ps1 script, thereby ensuring a successful deployment without errors related to the subscriptionID.

Copy link

@007zszmz 007zszmz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks nice.

Copy link
Contributor

@neelavarshad neelavarshad left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested and validated for required experience. Approved.

@neelavarshad neelavarshad merged commit c467dbd into Azure:main Jul 18, 2024
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants