feat(m365): Use Managed Identity for Getting Application Certificate in Container#6
Merged
feat(m365): Use Managed Identity for Getting Application Certificate in Container#6
Conversation
try new method for logging azcopy errors
Collaborator
Author
|
FYI @MichaelHicks-MSFT and @eagbaya Everything should be good to go, though I'd like to test in GCC High and confirm Microsoft's update has rolled out to all regions before merging. |
Collaborator
Author
|
Removing the |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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
Based on new features from Microsoft, this changes how we get the application's certificate inside the container.
With this change, we now use a User-Managed Identity to access key vault instead of passing the certificate as a secure environment variable.
This was previously unsupported when deploying in a vnet.
This also removes a configuration option for certificate expiration.
We no longer need to rotate frequently since the certificate remains in key vault, so the expiration is fixed at 1 year.
This also updates our terraform providers to the latest versions (needed for identities to work).
💭 Motivation and context
Previously we were passing the application certificate as a secure environment variable to the container.
This was not ideal, and had increased the risk of the certificate being leaked.
Since Microsoft has now added supported for using a Managed Identity inside an Azure Container Instance behind a vnet, this PR switches to using that for key vault access.
🧪 Testing
Tested in
westus2with and without a vnet and verified certificate installed in the container