From 29d035be5add0feaf8c036060405f33f4197d017 Mon Sep 17 00:00:00 2001 From: SDKAuto Date: Fri, 1 Apr 2022 00:57:48 +0000 Subject: [PATCH] CodeGen from PR 18138 in Azure/azure-rest-api-specs KubernetesConfiguration 2022-04-02-preview version changes (#18138) * Add 2022-03-01 version files as base commit * 2022-04-02-preview version changes * Readme changes * Update parameters version * update the example files with 2022-04-02 version * prettier and fixing the tooling issues * Some more object fixes * code review comments got fixed and used common types * Fixing more tooling issues and fixed all the code review comments * Code review comments got fixed. * Removing the paging as we always have 1 entry per resource type. * copied the 2022-01-01-preview files to 2022-04-02-preview to avoid the sdk generation issues. * Fixing the swagger lintdiff * Fixed the Avacado error * Removing the extensiontypes json * update readme.python Co-authored-by: Sathish Kulal Co-authored-by: Jiefeng Chen (WICRESOFT NORTH AMERICA LTD) --- .../Microsoft.KubernetesConfiguration.json | 655 ++++++++++++++++++ schemas/common/autogeneratedResources.json | 6 + 2 files changed, 661 insertions(+) create mode 100644 schemas/2022-04-02-preview/Microsoft.KubernetesConfiguration.json diff --git a/schemas/2022-04-02-preview/Microsoft.KubernetesConfiguration.json b/schemas/2022-04-02-preview/Microsoft.KubernetesConfiguration.json new file mode 100644 index 0000000000..f0d2e69ef4 --- /dev/null +++ b/schemas/2022-04-02-preview/Microsoft.KubernetesConfiguration.json @@ -0,0 +1,655 @@ +{ + "id": "https://schema.management.azure.com/schemas/2022-04-02-preview/Microsoft.KubernetesConfiguration.json#", + "$schema": "http://json-schema.org/draft-04/schema#", + "title": "Microsoft.KubernetesConfiguration", + "description": "Microsoft KubernetesConfiguration Resource Types", + "resourceDefinitions": { + "privateLinkScopes": { + "type": "object", + "properties": { + "apiVersion": { + "type": "string", + "enum": [ + "2022-04-02-preview" + ] + }, + "location": { + "type": "string", + "description": "The geo-location where the resource lives" + }, + "name": { + "type": "string", + "description": "The name of the Azure Arc PrivateLinkScope resource." + }, + "properties": { + "oneOf": [ + { + "$ref": "#/definitions/KubernetesConfigurationPrivateLinkScopeProperties" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Properties that define a Azure Arc PrivateLinkScope resource." + }, + "resources": { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/definitions/privateLinkScopes_privateEndpointConnections_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.KubernetesConfiguration/privateLinkScopes" + ] + } + }, + "required": [ + "apiVersion", + "location", + "name", + "properties", + "type" + ], + "description": "Microsoft.KubernetesConfiguration/privateLinkScopes" + }, + "privateLinkScopes_privateEndpointConnections": { + "type": "object", + "properties": { + "apiVersion": { + "type": "string", + "enum": [ + "2022-04-02-preview" + ] + }, + "name": { + "type": "string", + "description": "The name of the private endpoint connection associated with the Azure resource" + }, + "properties": { + "oneOf": [ + { + "$ref": "#/definitions/PrivateEndpointConnectionProperties" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Properties of the PrivateEndpointConnectProperties." + }, + "type": { + "type": "string", + "enum": [ + "Microsoft.KubernetesConfiguration/privateLinkScopes/privateEndpointConnections" + ] + } + }, + "required": [ + "apiVersion", + "name", + "properties", + "type" + ], + "description": "Microsoft.KubernetesConfiguration/privateLinkScopes/privateEndpointConnections" + } + }, + "extension_resourceDefinitions": { + "extensions": { + "type": "object", + "properties": { + "apiVersion": { + "type": "string", + "enum": [ + "2022-04-02-preview" + ] + }, + "identity": { + "oneOf": [ + { + "$ref": "#/definitions/Identity" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Identity for the resource." + }, + "name": { + "type": "string", + "description": "Name of the Extension." + }, + "plan": { + "oneOf": [ + { + "$ref": "#/definitions/Plan" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Plan for the resource." + }, + "properties": { + "oneOf": [ + { + "$ref": "#/definitions/ExtensionProperties" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Properties of an Extension resource" + }, + "systemData": { + "oneOf": [ + { + "$ref": "#/definitions/SystemData" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Metadata pertaining to creation and last modification of the resource." + }, + "type": { + "type": "string", + "enum": [ + "Microsoft.KubernetesConfiguration/extensions" + ] + } + }, + "required": [ + "apiVersion", + "name", + "properties", + "type" + ], + "description": "Microsoft.KubernetesConfiguration/extensions" + } + }, + "definitions": { + "ExtensionProperties": { + "type": "object", + "properties": { + "aksAssignedIdentity": { + "oneOf": [ + { + "$ref": "#/definitions/ExtensionPropertiesAksAssignedIdentity" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Identity of the Extension resource in an AKS cluster" + }, + "autoUpgradeMinorVersion": { + "oneOf": [ + { + "type": "boolean", + "default": true + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Flag to note if this extension participates in auto upgrade of minor version, or not." + }, + "configurationProtectedSettings": { + "oneOf": [ + { + "type": "object", + "additionalProperties": { + "type": "string" + }, + "properties": {} + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Configuration settings that are sensitive, as name-value pairs for configuring this extension." + }, + "configurationSettings": { + "oneOf": [ + { + "type": "object", + "additionalProperties": { + "type": "string" + }, + "properties": {} + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Configuration settings, as name-value pairs for configuring this extension." + }, + "extensionType": { + "type": "string", + "description": "Type of the Extension, of which this resource is an instance of. It must be one of the Extension Types registered with Microsoft.KubernetesConfiguration by the Extension publisher." + }, + "releaseTrain": { + "type": "string", + "default": "Stable", + "description": "ReleaseTrain this extension participates in for auto-upgrade (e.g. Stable, Preview, etc.) - only if autoUpgradeMinorVersion is 'true'." + }, + "scope": { + "oneOf": [ + { + "$ref": "#/definitions/Scope" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Scope of the extension. It can be either Cluster or Namespace; but not both." + }, + "statuses": { + "oneOf": [ + { + "type": "array", + "items": { + "$ref": "#/definitions/ExtensionStatus" + } + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Status from this extension." + }, + "version": { + "type": "string", + "description": "User-specified version of the extension for this extension to 'pin'. To use 'version', autoUpgradeMinorVersion must be 'false'." + } + }, + "description": "Properties of an Extension resource" + }, + "ExtensionPropertiesAksAssignedIdentity": { + "type": "object", + "properties": { + "type": { + "oneOf": [ + { + "type": "string", + "enum": [ + "SystemAssigned", + "UserAssigned" + ] + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "The identity type." + } + }, + "description": "Identity of the Extension resource in an AKS cluster" + }, + "ExtensionStatus": { + "type": "object", + "properties": { + "code": { + "type": "string", + "description": "Status code provided by the Extension" + }, + "displayStatus": { + "type": "string", + "description": "Short description of status of the extension." + }, + "level": { + "oneOf": [ + { + "type": "string", + "enum": [ + "Error", + "Warning", + "Information" + ] + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Level of the status." + }, + "message": { + "type": "string", + "description": "Detailed message of the status from the Extension." + }, + "time": { + "type": "string", + "description": "DateLiteral (per ISO8601) noting the time of installation status." + } + }, + "description": "Status from the extension." + }, + "Identity": { + "type": "object", + "properties": { + "type": { + "oneOf": [ + { + "type": "string", + "enum": [ + "SystemAssigned" + ] + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "The identity type." + } + }, + "description": "Identity for the resource." + }, + "KubernetesConfigurationPrivateLinkScopeProperties": { + "type": "object", + "properties": { + "clusterResourceId": { + "type": "string", + "description": "Managed Cluster ARM ID for the private link scope (Required)" + }, + "publicNetworkAccess": { + "oneOf": [ + { + "type": "string", + "enum": [ + "Enabled", + "Disabled" + ] + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Indicates whether machines associated with the private link scope can also use public Azure Arc service endpoints." + } + }, + "required": [ + "clusterResourceId" + ], + "description": "Properties that define a Azure Arc PrivateLinkScope resource." + }, + "Plan": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "A user defined name of the 3rd Party Artifact that is being procured." + }, + "product": { + "type": "string", + "description": "The 3rd Party artifact that is being procured. E.g. NewRelic. Product maps to the OfferID specified for the artifact at the time of Data Market onboarding. " + }, + "promotionCode": { + "type": "string", + "description": "A publisher provided promotion code as provisioned in Data Market for the said product/artifact." + }, + "publisher": { + "type": "string", + "description": "The publisher of the 3rd Party Artifact that is being bought. E.g. NewRelic" + }, + "version": { + "type": "string", + "description": "The version of the desired product/artifact." + } + }, + "required": [ + "name", + "product", + "publisher" + ], + "description": "Plan for the resource." + }, + "PrivateEndpoint": { + "type": "object", + "properties": {}, + "description": "The Private Endpoint resource." + }, + "PrivateEndpointConnectionProperties": { + "type": "object", + "properties": { + "privateEndpoint": { + "oneOf": [ + { + "$ref": "#/definitions/PrivateEndpoint" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "The Private Endpoint resource." + }, + "privateLinkServiceConnectionState": { + "oneOf": [ + { + "$ref": "#/definitions/PrivateLinkServiceConnectionState" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "A collection of information about the state of the connection between service consumer and provider." + }, + "provisioningState": { + "oneOf": [ + { + "type": "string", + "enum": [ + "Succeeded", + "Creating", + "Deleting", + "Failed" + ] + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "The provisioning state of the private endpoint connection resource." + } + }, + "required": [ + "privateLinkServiceConnectionState" + ], + "description": "Properties of the PrivateEndpointConnectProperties." + }, + "privateLinkScopes_privateEndpointConnections_childResource": { + "type": "object", + "properties": { + "apiVersion": { + "type": "string", + "enum": [ + "2022-04-02-preview" + ] + }, + "name": { + "type": "string", + "description": "The name of the private endpoint connection associated with the Azure resource" + }, + "properties": { + "oneOf": [ + { + "$ref": "#/definitions/PrivateEndpointConnectionProperties" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Properties of the PrivateEndpointConnectProperties." + }, + "type": { + "type": "string", + "enum": [ + "privateEndpointConnections" + ] + } + }, + "required": [ + "apiVersion", + "name", + "properties", + "type" + ], + "description": "Microsoft.KubernetesConfiguration/privateLinkScopes/privateEndpointConnections" + }, + "PrivateLinkServiceConnectionState": { + "type": "object", + "properties": { + "actionsRequired": { + "type": "string", + "description": "A message indicating if changes on the service provider require any updates on the consumer." + }, + "description": { + "type": "string", + "description": "The reason for approval/rejection of the connection." + }, + "status": { + "oneOf": [ + { + "type": "string", + "enum": [ + "Pending", + "Approved", + "Rejected" + ] + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Indicates whether the connection has been Approved/Rejected/Removed by the owner of the service." + } + }, + "description": "A collection of information about the state of the connection between service consumer and provider." + }, + "Scope": { + "type": "object", + "properties": { + "cluster": { + "oneOf": [ + { + "$ref": "#/definitions/ScopeCluster" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Specifies that the scope of the extension is Cluster" + }, + "namespace": { + "oneOf": [ + { + "$ref": "#/definitions/ScopeNamespace" + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "Specifies that the scope of the extension is Namespace" + } + }, + "description": "Scope of the extension. It can be either Cluster or Namespace; but not both." + }, + "ScopeCluster": { + "type": "object", + "properties": { + "releaseNamespace": { + "type": "string", + "description": "Namespace where the extension Release must be placed, for a Cluster scoped extension. If this namespace does not exist, it will be created" + } + }, + "description": "Specifies that the scope of the extension is Cluster" + }, + "ScopeNamespace": { + "type": "object", + "properties": { + "targetNamespace": { + "type": "string", + "description": "Namespace where the extension will be created for an Namespace scoped extension. If this namespace does not exist, it will be created" + } + }, + "description": "Specifies that the scope of the extension is Namespace" + }, + "SystemData": { + "type": "object", + "properties": { + "createdAt": { + "type": "string", + "format": "date-time", + "description": "The timestamp of resource creation (UTC)." + }, + "createdBy": { + "type": "string", + "description": "The identity that created the resource." + }, + "createdByType": { + "oneOf": [ + { + "type": "string", + "enum": [ + "User", + "Application", + "ManagedIdentity", + "Key" + ] + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "The type of identity that created the resource." + }, + "lastModifiedAt": { + "type": "string", + "format": "date-time", + "description": "The timestamp of resource last modification (UTC)" + }, + "lastModifiedBy": { + "type": "string", + "description": "The identity that last modified the resource." + }, + "lastModifiedByType": { + "oneOf": [ + { + "type": "string", + "enum": [ + "User", + "Application", + "ManagedIdentity", + "Key" + ] + }, + { + "$ref": "https://schema.management.azure.com/schemas/common/definitions.json#/definitions/expression" + } + ], + "description": "The type of identity that last modified the resource." + } + }, + "description": "Metadata pertaining to creation and last modification of the resource." + } + } +} \ No newline at end of file diff --git a/schemas/common/autogeneratedResources.json b/schemas/common/autogeneratedResources.json index 156954294d..ec8b077155 100644 --- a/schemas/common/autogeneratedResources.json +++ b/schemas/common/autogeneratedResources.json @@ -9574,6 +9574,12 @@ { "$ref": "https://schema.management.azure.com/schemas/2021-10-01/Microsoft.Kubernetes.json#/resourceDefinitions/connectedClusters" }, + { + "$ref": "https://schema.management.azure.com/schemas/2022-04-02-preview/Microsoft.KubernetesConfiguration.json#/resourceDefinitions/privateLinkScopes" + }, + { + "$ref": "https://schema.management.azure.com/schemas/2022-04-02-preview/Microsoft.KubernetesConfiguration.json#/resourceDefinitions/privateLinkScopes_privateEndpointConnections" + }, { "$ref": "https://schema.management.azure.com/schemas/2018-09-07-preview/Microsoft.Kusto.json#/resourceDefinitions/clusters" },