diff --git a/generator/whitelist.ts b/generator/whitelist.ts index 3dfbb424b2..8baccdb388 100644 --- a/generator/whitelist.ts +++ b/generator/whitelist.ts @@ -194,6 +194,10 @@ const whitelist: WhitelistConfig[] = [ namespace: 'Microsoft.DBforMariaDB', }, { + basePath: 'msi/resource-manager', + namespace: 'Microsoft.ManagedIdentity', + }, + { basePath: 'mysql/resource-manager', namespace: 'Microsoft.DBforMySQL', }, diff --git a/schemas/2015-08-31-preview/Microsoft.ManagedIdentity.json b/schemas/2015-08-31-preview/Microsoft.ManagedIdentity.json index 56a87a72a6..a5dd8d8e69 100644 --- a/schemas/2015-08-31-preview/Microsoft.ManagedIdentity.json +++ b/schemas/2015-08-31-preview/Microsoft.ManagedIdentity.json @@ -7,16 +7,6 @@ "userAssignedIdentities": { "type": "object", "properties": { - "name": { - "type": "string", - "description": "The name of the identity resource." - }, - "type": { - "type": "string", - "enum": [ - "Microsoft.ManagedIdentity/userAssignedIdentities" - ] - }, "apiVersion": { "type": "string", "enum": [ @@ -25,7 +15,11 @@ }, "location": { "type": "string", - "description": "The Azure region where the identity lives." + "description": "The Azure region where the resource lives." + }, + "name": { + "type": "string", + "description": "The name of the identity resource." }, "tags": { "oneOf": [ @@ -33,22 +27,29 @@ "type": "object", "additionalProperties": { "type": "string" - } + }, + "properties": {} }, { "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" } ], "description": "Resource tags" + }, + "type": { + "type": "string", + "enum": [ + "Microsoft.ManagedIdentity/userAssignedIdentities" + ] } }, "required": [ - "name", - "type", "apiVersion", - "location" + "name", + "type" ], "description": "Microsoft.ManagedIdentity/userAssignedIdentities" } - } -} \ No newline at end of file + }, + "definitions": {} +} \ No newline at end of file diff --git a/schemas/2018-11-30/Microsoft.ManagedIdentity.json b/schemas/2018-11-30/Microsoft.ManagedIdentity.json index 564a5d2e6c..0719837c24 100644 --- a/schemas/2018-11-30/Microsoft.ManagedIdentity.json +++ b/schemas/2018-11-30/Microsoft.ManagedIdentity.json @@ -7,16 +7,6 @@ "userAssignedIdentities": { "type": "object", "properties": { - "name": { - "type": "string", - "description": "The name of the identity resource." - }, - "type": { - "type": "string", - "enum": [ - "Microsoft.ManagedIdentity/userAssignedIdentities" - ] - }, "apiVersion": { "type": "string", "enum": [ @@ -25,7 +15,11 @@ }, "location": { "type": "string", - "description": "The Azure region where the identity lives." + "description": "The Azure region where the resource lives." + }, + "name": { + "type": "string", + "description": "The name of the identity resource." }, "tags": { "oneOf": [ @@ -33,22 +27,29 @@ "type": "object", "additionalProperties": { "type": "string" - } + }, + "properties": {} }, { "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" } ], "description": "Resource tags" + }, + "type": { + "type": "string", + "enum": [ + "Microsoft.ManagedIdentity/userAssignedIdentities" + ] } }, "required": [ - "name", - "type", "apiVersion", - "location" + "name", + "type" ], "description": "Microsoft.ManagedIdentity/userAssignedIdentities" } - } -} \ No newline at end of file + }, + "definitions": {} +} \ No newline at end of file diff --git a/schemas/2019-04-01/deploymentTemplate.json b/schemas/2019-04-01/deploymentTemplate.json index 9d58c42e1d..cfc45fd839 100644 --- a/schemas/2019-04-01/deploymentTemplate.json +++ b/schemas/2019-04-01/deploymentTemplate.json @@ -1320,8 +1320,6 @@ { "$ref": "https://schema.management.azure.com/schemas/2016-10-01/Microsoft.StorSimple.json#/resourceDefinitions/managers_storageAccountCredentials" }, { "$ref": "https://schema.management.azure.com/schemas/2016-10-01/Microsoft.StorSimple.json#/resourceDefinitions/managers_storageDomains" }, { "$ref": "https://schema.management.azure.com/schemas/2018-10-01/Microsoft.SignalRService.json#/resourceDefinitions/SignalR" }, - { "$ref": "https://schema.management.azure.com/schemas/2015-08-31-preview/Microsoft.ManagedIdentity.json#/resourceDefinitions/userAssignedIdentities" }, - { "$ref": "https://schema.management.azure.com/schemas/2018-11-30/Microsoft.ManagedIdentity.json#/resourceDefinitions/userAssignedIdentities" }, { "$ref": "https://schema.management.azure.com/schemas/2015-06-01-preview/Microsoft.Security.json#/resourceDefinitions/jitNetworkAccessPolicies" }, { "$ref": "https://schema.management.azure.com/schemas/2017-08-01-preview/Microsoft.Security.json#/resourceDefinitions/pricings" }, { "$ref": "https://schema.management.azure.com/schemas/2017-08-01-preview/Microsoft.Security.json#/resourceDefinitions/securityContacts" }, diff --git a/schemas/common/autogeneratedResources.json b/schemas/common/autogeneratedResources.json index 7021b5a512..6926482bb3 100644 --- a/schemas/common/autogeneratedResources.json +++ b/schemas/common/autogeneratedResources.json @@ -1516,6 +1516,12 @@ { "$ref": "https://schema.management.azure.com/schemas/2018-06-01-preview/Microsoft.Maintenance.json#/resourceDefinitions/maintenanceConfigurations" }, + { + "$ref": "https://schema.management.azure.com/schemas/2015-08-31-preview/Microsoft.ManagedIdentity.json#/resourceDefinitions/userAssignedIdentities" + }, + { + "$ref": "https://schema.management.azure.com/schemas/2018-11-30/Microsoft.ManagedIdentity.json#/resourceDefinitions/userAssignedIdentities" + }, { "$ref": "https://schema.management.azure.com/schemas/2019-06-01-preview/Microsoft.ManagedNetwork.json#/resourceDefinitions/managedNetworks" }, diff --git a/tests/2015-08-31-preview/Microsoft.ManagedIdentity.tests.json b/tests/2015-08-31-preview/Microsoft.ManagedIdentity.tests.json index 3f8c460b9b..2c40f9ba13 100644 --- a/tests/2015-08-31-preview/Microsoft.ManagedIdentity.tests.json +++ b/tests/2015-08-31-preview/Microsoft.ManagedIdentity.tests.json @@ -5,21 +5,17 @@ "definition": "https://schema.management.azure.com/schemas/2015-08-31-preview/Microsoft.ManagedIdentity.json#/resourceDefinitions/userAssignedIdentities", "expectedErrors": [ { - "message": "Missing required property: name", - "dataPath": "/" - }, - { - "message": "Missing required property: type", + "message": "Missing required property: apiVersion", "dataPath": "/" }, { - "message": "Missing required property: apiVersion", + "message": "Missing required property: name", "dataPath": "/" }, { - "message": "Missing required property: location", + "message": "Missing required property: type", "dataPath": "/" - } + } ], "json": { } }, @@ -30,7 +26,8 @@ "name": "id", "type": "Microsoft.ManagedIdentity/userAssignedIdentities", "apiVersion": "2015-08-31-preview", - "location": "West Us" + "location": "West Us", + "properties": {} } } ] diff --git a/tests/2018-11-30/Microsoft.ManagedIdentity.tests.json b/tests/2018-11-30/Microsoft.ManagedIdentity.tests.json index 37bb2af111..2243f069b6 100644 --- a/tests/2018-11-30/Microsoft.ManagedIdentity.tests.json +++ b/tests/2018-11-30/Microsoft.ManagedIdentity.tests.json @@ -5,21 +5,17 @@ "definition": "https://schema.management.azure.com/schemas/2018-11-30/Microsoft.ManagedIdentity.json#/resourceDefinitions/userAssignedIdentities", "expectedErrors": [ { - "message": "Missing required property: name", - "dataPath": "/" - }, - { - "message": "Missing required property: type", + "message": "Missing required property: apiVersion", "dataPath": "/" }, { - "message": "Missing required property: apiVersion", + "message": "Missing required property: name", "dataPath": "/" }, { - "message": "Missing required property: location", + "message": "Missing required property: type", "dataPath": "/" - } + } ], "json": { } }, @@ -30,7 +26,8 @@ "name": "id", "type": "Microsoft.ManagedIdentity/userAssignedIdentities", "apiVersion": "2018-11-30", - "location": "West Us" + "location": "West Us", + "properties": {} } } ]