From 5c6ded18b8fa85238fac02f2937734e417e6e144 Mon Sep 17 00:00:00 2001 From: SDKAuto Date: Mon, 18 Apr 2022 10:36:31 +0000 Subject: [PATCH] CodeGen from PR 18629 in Azure/azure-rest-api-specs [Hub Generated] Publish private branch 'stuartko/Jan22_TSBuiltInsWithApiVersionBump' (#18629) * Copy previous version to 2022-02-01 directory * Adding changed spec files from PR 4200. Without api-version bump * Changing version string 2021-06-01 to 2022-02-01 in specs * Updating SDK generation tags/settings to use 2022-02 * Fixing some LintDiff issues (new rules) * Fixing "prettier" issue * Fixing bad conflict resolution --- .../subscriptionDeploymentTemplate.json | 3 + schemas/2022-02-01/Microsoft.Resources.json | 364 ++++++++++++++++++ schemas/common/autogeneratedResources.json | 6 + 3 files changed, 373 insertions(+) create mode 100644 schemas/2022-02-01/Microsoft.Resources.json diff --git a/schemas/2018-05-01/subscriptionDeploymentTemplate.json b/schemas/2018-05-01/subscriptionDeploymentTemplate.json index c78e27d3d8..3165cde89a 100644 --- a/schemas/2018-05-01/subscriptionDeploymentTemplate.json +++ b/schemas/2018-05-01/subscriptionDeploymentTemplate.json @@ -1235,6 +1235,9 @@ { "$ref": "https://schema.management.azure.com/schemas/2021-05-01/Microsoft.Resources.json#/subscription_resourceDefinitions/resourceGroups" }, + { + "$ref": "https://schema.management.azure.com/schemas/2022-02-01/Microsoft.Resources.json#/subscription_resourceDefinitions/resourceGroups" + }, { "$ref": "https://schema.management.azure.com/schemas/2015-06-01-preview/Microsoft.Security.json#/subscription_resourceDefinitions/locations_applicationWhitelistings" }, diff --git a/schemas/2022-02-01/Microsoft.Resources.json b/schemas/2022-02-01/Microsoft.Resources.json new file mode 100644 index 0000000000..e2291cdd22 --- /dev/null +++ b/schemas/2022-02-01/Microsoft.Resources.json @@ -0,0 +1,364 @@ +{ + "id": "https://schema.management.azure.com/schemas/2022-02-01/Microsoft.Resources.json#", + "$schema": "http://json-schema.org/draft-04/schema#", + "title": "Microsoft.Resources", + "description": "Microsoft Resources Resource Types", + "resourceDefinitions": { + "templateSpecs": { + "type": "object", + "properties": { + "apiVersion": { + "type": "string", + "enum": [ + "2022-02-01" + ] + }, + "location": { + "type": "string", + "description": "The location of the Template Spec. It cannot be changed after Template Spec creation. It must be one of the supported Azure locations." + }, + "name": { + "oneOf": [ + { + "type": "string", + "pattern": "^[-\\w\\._\\(\\)]+$", + "minLength": 1, + "maxLength": 90 + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Name of the Template Spec." + }, + "properties": { + "oneOf": [ + { + "$ref": "#/definitions/TemplateSpecProperties" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Template Spec properties." + }, + "resources": { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/definitions/templateSpecs_versions_childResource" + } + ] + } + }, + "tags": { + "oneOf": [ + { + "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.Resources/templateSpecs" + ] + } + }, + "required": [ + "apiVersion", + "location", + "name", + "properties", + "type" + ], + "description": "Microsoft.Resources/templateSpecs" + }, + "templateSpecs_versions": { + "type": "object", + "properties": { + "apiVersion": { + "type": "string", + "enum": [ + "2022-02-01" + ] + }, + "location": { + "type": "string", + "description": "The location of the Template Spec Version. It must match the location of the parent Template Spec." + }, + "name": { + "oneOf": [ + { + "type": "string", + "pattern": "^[-\\w\\._\\(\\)]+$", + "minLength": 1, + "maxLength": 90 + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "The version of the Template Spec." + }, + "properties": { + "oneOf": [ + { + "$ref": "#/definitions/TemplateSpecVersionProperties" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Template Spec Version properties." + }, + "tags": { + "oneOf": [ + { + "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.Resources/templateSpecs/versions" + ] + } + }, + "required": [ + "apiVersion", + "location", + "name", + "properties", + "type" + ], + "description": "Microsoft.Resources/templateSpecs/versions" + } + }, + "definitions": { + "LinkedTemplateArtifact": { + "type": "object", + "properties": { + "path": { + "type": "string", + "description": "A filesystem safe relative path of the artifact." + }, + "template": { + "type": "object", + "properties": {}, + "description": "The Azure Resource Manager template." + } + }, + "required": [ + "path", + "template" + ], + "description": "Represents a Template Spec artifact containing an embedded Azure Resource Manager template for use as a linked template." + }, + "TemplateSpecProperties": { + "type": "object", + "properties": { + "description": { + "type": "string", + "maxLength": 4096, + "description": "Template Spec description." + }, + "displayName": { + "type": "string", + "maxLength": 64, + "description": "Template Spec display name." + }, + "metadata": { + "type": "object", + "properties": {}, + "description": "The Template Spec metadata. Metadata is an open-ended object and is typically a collection of key-value pairs." + } + }, + "description": "Template Spec properties." + }, + "templateSpecs_versions_childResource": { + "type": "object", + "properties": { + "apiVersion": { + "type": "string", + "enum": [ + "2022-02-01" + ] + }, + "location": { + "type": "string", + "description": "The location of the Template Spec Version. It must match the location of the parent Template Spec." + }, + "name": { + "oneOf": [ + { + "type": "string", + "pattern": "^[-\\w\\._\\(\\)]+$", + "minLength": 1, + "maxLength": 90 + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "The version of the Template Spec." + }, + "properties": { + "oneOf": [ + { + "$ref": "#/definitions/TemplateSpecVersionProperties" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Template Spec Version properties." + }, + "tags": { + "oneOf": [ + { + "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": [ + "versions" + ] + } + }, + "required": [ + "apiVersion", + "location", + "name", + "properties", + "type" + ], + "description": "Microsoft.Resources/templateSpecs/versions" + }, + "TemplateSpecVersionProperties": { + "type": "object", + "properties": { + "description": { + "type": "string", + "maxLength": 4096, + "description": "Template Spec version description." + }, + "linkedTemplates": { + "oneOf": [ + { + "type": "array", + "items": { + "$ref": "#/definitions/LinkedTemplateArtifact" + } + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "An array of linked template artifacts." + }, + "mainTemplate": { + "type": "object", + "properties": {}, + "description": "The main Azure Resource Manager template content." + }, + "metadata": { + "type": "object", + "properties": {}, + "description": "The version metadata. Metadata is an open-ended object and is typically a collection of key-value pairs." + }, + "uiFormDefinition": { + "type": "object", + "properties": {}, + "description": "The Azure Resource Manager template UI definition content." + } + }, + "description": "Template Spec Version properties." + } + }, + "subscription_resourceDefinitions": { + "resourceGroups": { + "type": "object", + "properties": { + "name": { + "oneOf": [ + { + "type": "string", + "pattern": "^[-\\w\\._\\(\\)]+$", + "maxLength": 90, + "description": "the resource group name" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ] + }, + "type": { + "type": "string", + "enum": [ + "Microsoft.Resources/resourceGroups" + ] + }, + "apiVersion": { + "type": "string", + "enum": [ + "2022-02-01" + ] + }, + "location": { + "type": "string", + "description": "the resource group location" + }, + "tags": { + "oneOf": [ + { + "type": "object", + "additionalProperties": { + "type": "string" + } + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "The resource group tags." + } + }, + "required": [ + "name", + "type", + "apiVersion", + "location" + ], + "description": "Microsoft.Resources/resourceGroups" + } + } +} \ No newline at end of file diff --git a/schemas/common/autogeneratedResources.json b/schemas/common/autogeneratedResources.json index b99518f62e..963e1cdac7 100644 --- a/schemas/common/autogeneratedResources.json +++ b/schemas/common/autogeneratedResources.json @@ -12571,6 +12571,12 @@ { "$ref": "https://schema.management.azure.com/schemas/2021-05-01/Microsoft.Resources.json#/resourceDefinitions/templateSpecs_versions" }, + { + "$ref": "https://schema.management.azure.com/schemas/2022-02-01/Microsoft.Resources.json#/resourceDefinitions/templateSpecs" + }, + { + "$ref": "https://schema.management.azure.com/schemas/2022-02-01/Microsoft.Resources.json#/resourceDefinitions/templateSpecs_versions" + }, { "$ref": "https://schema.management.azure.com/schemas/2014-08-01-preview/Microsoft.Scheduler.json#/resourceDefinitions/jobCollections" },