Add Azure sovereign cloud support#1255
Add Azure sovereign cloud support#1255gtardif merged 1 commit intodocker-archive:mainfrom karolz-ms:658-azure-sovereign-clouds
Conversation
|
Hi @karolz-ms, a couple of things that might help related to linter errors :
|
Thanks, @gtardif Hopefully I got everything fixed with my last change. I am now running |
gtardif
left a comment
There was a problem hiding this comment.
Mainly check if we can store the desired cloudEnvironment earlier in structs, rather than have a lazy compute.
Also, in terms of migration from previous versions, I tried to install this version and just run a command (without re-login), I received cannot get container group client: Cloud environment '' was not found.
We should assume azure public cloud by default if we can't find a previous cloud name in tokenInfo.
Looks all right with the linter. Sorry I added more remarks today (more useful regarding the actual PR content) |
|
I am working on suggested changes, many thanks @gtardif! Please hold off on reviewing again until I let you know the branch is ready. |
Signed-off-by: Karol Zadora-Przylecki <karolz@microsoft.com>
|
@gtardif I think this should be better, please take another look. I did run the ACI E2E tests, |
|
The only thing missing I think is setting public cloud as the default if we don't find any cloud name in the json file. |
Hmm, I thought this addition would address this scenario, but apparently there is more to it. I will take a look |
Indeed, that would seem to address this. I haven't debugged it to investigate more why this doesn't do the trick... |
|
I will let you know what I find; I can probably figure it out on my own unless I cannot reproduce. |
|
@gtardif so I cannot reproduce the problem. What I did:
Perhaps you were inadvertently running the older version of the code during your testing? |
|
Oops sorry, my bad, I probably missed something when updating from your PR, and was running the previous code. Checked again, works all fine. |
Signed-off-by: Karol Zadora-Przylecki karolz@microsoft.com
What I did
Added a notion of "cloud environment" for Azure integration. This allows Docker CLI to work with "sovereign" clouds like Azure China, Azure US Government etc.
Related issue
Fixes #658
This PR does not include documentation changes
This PR does not add new E2E (integration) tests--I was not sure if you want to have any that target non-public Azure clouds. Even for teams inside Microsoft it is not always the case that we have automated tests targeting non-public clouds, so I think unit tests are good enough for a start.