{CI} Add /azure-cli as safe.directory in docker container#22049
Merged
{CI} Add /azure-cli as safe.directory in docker container#22049
/azure-cli as safe.directory in docker container#22049Conversation
Collaborator
|
CI |
yonzhan
approved these changes
Apr 13, 2022
wangzelin007
approved these changes
Apr 13, 2022
zhoxing-ms
approved these changes
Apr 13, 2022
jsntcy
approved these changes
Apr 13, 2022
Member
Author
|
The error can be easily reproduced locally on Ubuntu WSL: |
evelyn-ys
approved these changes
Apr 13, 2022
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
Git released a fix for CVE-2022-24765 today, making it impossible to run
gitcommands in a directory that is not owned by the current user:This fix was backported to
2.25.1-1ubuntu3.3on Ubuntu Focal (https://launchpad.net/ubuntu/+source/git/1:2.25.1-1ubuntu3.3), causing CI failure:https://dev.azure.com/azure-sdk/public/_build/results?buildId=1501323&view=logs&j=6a6a2ac0-ff7f-5678-6bf3-3c1acb42be6f&t=9fdc6347-bbbe-562a-7659-31ca5019fc37
As it is expected for mounted
/azure-clito have different owner than the current docker container's user, this PR adds/azure-cliassafe.directory.Other Microsoft developers are taking the same approach: https://github.com/microsoft/openocd/commit/16d4838818c5a67cb7739d948582c5e63095ceed (found by https://github.com/search?q=org%3Amicrosoft+safe.directory+git+config&type=code)