Add support for Azure Government Cloud (GovCloud) environments #134
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.
This PR adds comprehensive support for Azure Government Cloud environments to Azure Key Vault Explorer, allowing users to connect to both Azure Commercial and Azure US Government clouds.
Changes Made
Cloud Environment Configuration
CloudEnvironment
class with predefined configurations for Public and US Government cloudsAzureCloud
enum to represent different cloud typesAppSettings
with validationAuthentication Updates
AuthService
to use cloud-specific authorities:login.microsoftonline.com
login.microsoftonline.us
vault.azure.net
,management.core.windows.net
vault.usgovcloudapi.net
,management.usgovcloudapi.net
User Interface
Portal Integration
portal.azure.com
portal.azure.us
Key Features
Multi-Cloud Support: Users can now select between Azure Public Cloud and Azure US Government from a dropdown in Settings.
Automatic Configuration: All endpoints (authentication, Key Vault API, Resource Manager API, and portal URLs) are automatically configured based on the selected cloud environment.
Backwards Compatibility: Existing installations continue to use Azure Public Cloud by default with no changes required.
Settings Persistence: Cloud selection is saved to user settings and persists between application restarts.
Testing
Created comprehensive tests validating:
Usage
This implementation provides a complete solution for organizations requiring Azure Government Cloud access while maintaining full compatibility for existing commercial Azure users.
Fixes #122.
Warning
Firewall rules blocked me from connecting to one or more addresses (expand for details)
I tried to connect to the following addresses, but was blocked by firewall rules:
av-build-tel-api-v1.avaloniaui.net
dotnet exec --runtimeconfig /home/REDACTED/.nuget/packages/avalonia.buildservices/0.0.31/tools/netstandard2.0/runtimeconfig.json /home/REDACTED/.nuget/packages/avalonia.buildservices/0.0.31/tools/netstandard2.0/Avalonia.BuildServices.Collector.dll
(dns block)dotnet build --verbosity minimal
(dns block)If you need me to access, download, or install something from one of these locations, you can either:
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.