Azure Monitor: Remove references to Germany cloud (#60588)

This commit is contained in:
Andres Martinez Gotor
2022-12-21 11:51:57 +01:00
committed by GitHub
parent 2533b44cb6
commit 733dbe0163
10 changed files with 7 additions and 25 deletions
-1
View File
@@ -15,7 +15,6 @@ const (
azureMonitorPublic = "azuremonitor"
azureMonitorChina = "chinaazuremonitor"
azureMonitorUSGovernment = "govazuremonitor"
azureMonitorGermany = "germanyazuremonitor"
azureMonitorCustomized = "customizedazuremonitor"
)
+2 -2
View File
@@ -88,7 +88,7 @@ func TestCredentials_getAzureCloud(t *testing.T) {
t.Run("when auth type is managed identity", func(t *testing.T) {
jsonData := simplejson.NewFromAny(map[string]interface{}{
"azureAuthType": azcredentials.AzureAuthManagedIdentity,
"cloudName": azureMonitorGermany,
"cloudName": azureMonitorUSGovernment,
})
t.Run("should be from server configuration regardless of datasource value", func(t *testing.T) {
@@ -153,7 +153,7 @@ func TestCredentials_getAzureCredentials(t *testing.T) {
t.Run("when auth type is managed identity", func(t *testing.T) {
jsonData := simplejson.NewFromAny(map[string]interface{}{
"azureAuthType": azcredentials.AzureAuthManagedIdentity,
"cloudName": azureMonitorGermany,
"cloudName": azureMonitorUSGovernment,
"tenantId": "9b9d90ee-a5cc-49c2-b97e-0d1b0f086b5c",
"clientId": "849ccbb0-92eb-4226-b228-ef391abd8fe6",
})
-6
View File
@@ -25,12 +25,6 @@ var azUSGovManagement = types.AzRoute{
Headers: map[string]string{"x-ms-app": "Grafana"},
}
var azGermanyManagement = types.AzRoute{
URL: "https://management.microsoftazure.de",
Scopes: []string{"https://management.microsoftazure.de/.default"},
Headers: map[string]string{"x-ms-app": "Grafana"},
}
var azChinaManagement = types.AzRoute{
URL: "https://management.chinacloudapi.cn",
Scopes: []string{"https://management.chinacloudapi.cn/.default"},