Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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 thesubscriptionID
is properly assigned. This premature API call results in an error due to the lack of a validsubscriptionID
. 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
Deploy.ps1
script to ensure that thesubscriptionID
is assigned before any API calls are made. This change prevents the aforementioned error by ensuring that a validsubscriptionID
is available for the API call that checks for the existence of a KeyVault.Impact
subscriptionID
before making the API call, we avoid theInvalidSubscriptionId
error and ensure a smoother deployment process.Testing
subscriptionID
is correctly assigned before the API call is made. This ensures that the deployment process proceeds without encountering theInvalidSubscriptionId
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 thesubscriptionID
.