diff --git a/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/communityGallery.json b/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/communityGallery.json index 905915f4ffd2..1317907d6aca 100644 --- a/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/communityGallery.json +++ b/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/communityGallery.json @@ -168,6 +168,99 @@ } } } + }, + "/subscriptions/{subscriptionId}/providers/Microsoft.Compute/locations/{location}/communityGalleries/{publicGalleryName}/images": { + "get": { + "tags": [ + "CommunityGalleryImages" + ], + "operationId": "CommunityGalleryImages_List", + "description": "List community gallery images inside a gallery.", + "parameters": [ + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/LocationNameParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + }, + { + "$ref": "#/parameters/PublicGalleryNameParameter" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/CommunityGalleryImageList" + } + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "#/definitions/CloudError" + } + } + }, + "x-ms-examples": { + "Get a gallery.": { + "$ref": "./examples/communityGallery/ListCommunityGalleryImages.json" + } + }, + "x-ms-pageable": { + "nextLinkName": "nextLink" + } + } + }, + "/subscriptions/{subscriptionId}/providers/Microsoft.Compute/locations/{location}/communityGalleries/{publicGalleryName}/images/{galleryImageName}/versions": { + "get": { + "tags": [ + "CommunityGalleryImageVersions" + ], + "operationId": "CommunityGalleryImageVersions_List", + "description": "List community gallery image versions inside an image.", + "parameters": [ + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/LocationNameParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + }, + { + "$ref": "#/parameters/PublicGalleryNameParameter" + }, + { + "$ref": "#/parameters/GalleryImageNameParameter" + } + ], + "responses": { + "200": { + "description": "OK", + "schema": { + "$ref": "#/definitions/CommunityGalleryImageVersionList" + } + }, + "default": { + "description": "Error response describing why the operation failed.", + "schema": { + "$ref": "#/definitions/CloudError" + } + } + }, + "x-ms-examples": { + "Get a gallery.": { + "$ref": "./examples/communityGallery/ListCommunityGalleryImageVersions.json" + } + }, + "x-ms-pageable": { + "nextLinkName": "nextLink" + } + } } }, "definitions": { @@ -213,6 +306,25 @@ ], "description": "Specifies information about the Community Gallery that you want to create or update." }, + "CommunityGalleryImageList": { + "description": "The List Community Gallery Images operation response.", + "properties": { + "value": { + "type": "array", + "items": { + "$ref": "#/definitions/CommunityGalleryImage" + }, + "description": "A list of community gallery images." + }, + "nextLink": { + "type": "string", + "description": "The uri to fetch the next page of community gallery images. Call ListNext() with this to fetch the next page of community gallery images." + } + }, + "required": [ + "value" + ] + }, "CommunityGalleryImage": { "properties": { "properties": { @@ -291,6 +403,14 @@ }, "purchasePlan": { "$ref": "#/definitions/ImagePurchasePlan" + }, + "privacyStatementUri": { + "type": "string", + "description": "The uri to describe the privacy statement issued from community gallery publisher." + }, + "eula": { + "type": "string", + "description": "The uri to describe the eula issued from community gallery publisher." } }, "required": [ @@ -390,6 +510,25 @@ }, "description": "Describes the gallery image definition purchase plan. This is used by marketplace images." }, + "CommunityGalleryImageVersionList": { + "description": "The List Community Gallery Image versions operation response.", + "properties": { + "value": { + "type": "array", + "items": { + "$ref": "#/definitions/CommunityGalleryImageVersion" + }, + "description": "A list of community gallery image versions." + }, + "nextLink": { + "type": "string", + "description": "The uri to fetch the next page of community gallery image versions. Call ListNext() with this to fetch the next page of community gallery image versions." + } + }, + "required": [ + "value" + ] + }, "CommunityGalleryImageVersion": { "properties": { "properties": { @@ -415,10 +554,82 @@ "type": "string", "format": "date-time", "description": "The end of life date of the gallery image version Definition. This property can be used for decommissioning purposes. This property is updatable." + }, + "excludeFromLatest": { + "type": "boolean", + "description": "If set to true, Virtual Machines deployed from the latest version of the Image Definition won't use this Image Version." + }, + "storageProfile": { + "$ref": "#/definitions/CommunityGalleryImageVersionStorageProfile" } }, "description": "Describes the properties of a gallery image version." }, + "CommunityGalleryImageVersionStorageProfile": { + "properties": { + "osDiskImage": { + "$ref": "#/definitions/CommunityGalleryOSDiskImage" + }, + "dataDiskImages": { + "type": "array", + "items": { + "$ref": "#/definitions/CommunityGalleryDataDiskImage" + }, + "description": "A list of data disk images." + } + }, + "description": "This is the storage profile of a Gallery Image Version." + }, + "CommunityGalleryOSDiskImage": { + "allOf": [ + { + "$ref": "#/definitions/CommunityGalleryDiskImage" + } + ], + "description": "This is the OS disk image." + }, + "CommunityGalleryDataDiskImage": { + "properties": { + "lun": { + "type": "integer", + "format": "int32", + "description": "This property specifies the logical unit number of the data disk. This value is used to identify data disks within the Virtual Machine and therefore must be unique for each data disk attached to the Virtual Machine." + } + }, + "allOf": [ + { + "$ref": "#/definitions/CommunityGalleryDiskImage" + } + ], + "required": [ + "lun" + ], + "description": "This is the data disk image." + }, + "CommunityGalleryDiskImage": { + "properties": { + "sizeInGB": { + "readOnly": true, + "type": "integer", + "format": "int32", + "description": "This property indicates the size of the VHD to be created." + }, + "hostCaching": { + "type": "string", + "description": "The host caching of the disk. Valid values are 'None', 'ReadOnly', and 'ReadWrite'", + "enum": [ + "None", + "ReadOnly", + "ReadWrite" + ], + "x-ms-enum": { + "name": "HostCaching", + "modelAsString": false + } + } + }, + "description": "This is the disk image base class." + }, "CloudError": { "x-ms-external": true, "properties": { diff --git a/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/examples/communityGallery/GetACommunityGalleryImage.json b/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/examples/communityGallery/GetACommunityGalleryImage.json index d7ff0d54839a..6fdee3bf33ac 100644 --- a/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/examples/communityGallery/GetACommunityGalleryImage.json +++ b/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/examples/communityGallery/GetACommunityGalleryImage.json @@ -13,6 +13,8 @@ "osType": "Windows", "osState": "Generalized", "hyperVGeneration": "V1", + "privacyStatementUri": "http://privacyStatementUri.com", + "eula": "publisherEulaString", "identifier": { "publisher": "myPublisherName", "offer": "myOfferName", diff --git a/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/examples/communityGallery/ListCommunityGalleryImageVersions.json b/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/examples/communityGallery/ListCommunityGalleryImageVersions.json new file mode 100644 index 000000000000..a34ef4200c21 --- /dev/null +++ b/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/examples/communityGallery/ListCommunityGalleryImageVersions.json @@ -0,0 +1,29 @@ +{ + "parameters": { + "subscriptionId": "{subscription-id}", + "location": "myLocation", + "api-version": "2021-07-01", + "publicGalleryName": "publicGalleryName", + "galleryImageName": "myGalleryImageName" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "properties": { + "publishedDate": "2018-03-20T09:12:28Z", + "endOfLifeDate": "2022-03-20T09:12:28Z" + }, + "location": "myLocation", + "name": "myGalleryImageVersionName", + "identifier": { + "uniqueId": "/CommunityGalleries/publicGalleryName/Images/myGalleryImageName/Versions/myGalleryImageVersionName" + } + } + ], + "nextLink": "http://svchost:99/subscriptions/{subscription-Id}/providers/Microsoft.Compute/communityGalleries/publicGalleryName/images/myGalleryImageName/versions?$skiptoken={token}/communityGalleries/publicGalleryName/images/myGalleryImageName/versions/myGalleryImageVersionName" + } + } + } +} diff --git a/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/examples/communityGallery/ListCommunityGalleryImages.json b/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/examples/communityGallery/ListCommunityGalleryImages.json new file mode 100644 index 000000000000..9879139d5cb6 --- /dev/null +++ b/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/examples/communityGallery/ListCommunityGalleryImages.json @@ -0,0 +1,34 @@ +{ + "parameters": { + "subscriptionId": "{subscription-id}", + "location": "myLocation", + "api-version": "2021-07-01", + "publicGalleryName": "publicGalleryName" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "properties": { + "osType": "Windows", + "osState": "Generalized", + "hyperVGeneration": "V1", + "identifier": { + "publisher": "myPublisherName", + "offer": "myOfferName", + "sku": "mySkuName" + } + }, + "location": "myLocation", + "name": "myGalleryImageName", + "identifier": { + "uniqueId": "/CommunityGalleries/publicGalleryName/Images/myGalleryImageName" + } + } + ], + "nextLink": "http://svchost:99/subscriptions/{subscription-Id}/providers/Microsoft.Compute/communityGalleries/publicGalleryName/images?$skiptoken={token}/communityGalleries/publicGalleryName/images/myGalleryImageName" + } + } + } +} diff --git a/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/examples/gallery/CreateACommunityGallery.json b/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/examples/gallery/CreateACommunityGallery.json new file mode 100644 index 000000000000..325106afe66d --- /dev/null +++ b/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/examples/gallery/CreateACommunityGallery.json @@ -0,0 +1,91 @@ +{ + "parameters": { + "subscriptionId": "{subscription-id}", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-01", + "galleryName": "myGalleryName", + "gallery": { + "location": "West US", + "properties": { + "description": "This is the gallery description.", + "sharingProfile": { + "permissions": "Community", + "communityGalleryInfo": { + "publisherUri": "uri", + "publisherContact": "pir@microsoft.com", + "eula": "eula", + "publicNamePrefix": "PirPublic" + } + } + } + } + }, + "responses": { + "200": { + "body": { + "properties": { + "description": "This is the gallery description.", + "identifier": { + "uniqueName": "{subscription-id}-MYGALLERYNAME" + }, + "provisioningState": "Updating", + "sharingProfile": { + "permissions": "Community", + "communityGalleryInfo": { + "publisherUri": "uri", + "publisherContact": "pir@microsoft.com", + "eula": "eula", + "publicNamePrefix": "PirPublic" + } + } + }, + "location": "West US", + "name": "myGalleryName" + } + }, + "201": { + "body": { + "properties": { + "description": "This is the gallery description.", + "identifier": { + "uniqueName": "{subscription-id}-MYGALLERYNAME" + }, + "provisioningState": "Creating", + "sharingProfile": { + "permissions": "Community", + "communityGalleryInfo": { + "publisherUri": "uri", + "publisherContact": "pir@microsoft.com", + "eula": "eula", + "publicNamePrefix": "PirPublic" + } + } + }, + "location": "West US", + "name": "myGalleryName" + } + }, + "202": { + "body": { + "properties": { + "description": "This is the gallery description.", + "identifier": { + "uniqueName": "{subscription-id}-MYGALLERYNAME" + }, + "provisioningState": "Updating", + "sharingProfile": { + "permissions": "Community", + "communityGalleryInfo": { + "publisherUri": "uri", + "publisherContact": "pir@microsoft.com", + "eula": "eula", + "publicNamePrefix": "PirPublic" + } + } + }, + "location": "West US", + "name": "myGalleryName" + } + } + } +} diff --git a/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/examples/gallery/EnableACommunityGallery.json b/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/examples/gallery/EnableACommunityGallery.json new file mode 100644 index 000000000000..164f0d2e4581 --- /dev/null +++ b/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/examples/gallery/EnableACommunityGallery.json @@ -0,0 +1,23 @@ +{ + "parameters": { + "subscriptionId": "{subscription-id}", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-01", + "galleryName": "myGalleryName", + "sharingUpdate": { + "operationType": "EnableCommunity" + } + }, + "responses": { + "200": { + "body": { + "operationType": "EnableCommunity" + } + }, + "202": { + "body": { + "operationType": "EnableCommunity" + } + } + } +} diff --git a/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/examples/gallery/GetACommunityGallery.json b/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/examples/gallery/GetACommunityGallery.json new file mode 100644 index 000000000000..a307c1967594 --- /dev/null +++ b/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/examples/gallery/GetACommunityGallery.json @@ -0,0 +1,45 @@ +{ + "parameters": { + "subscriptionId": "{subscription-id}", + "resourceGroupName": "myResourceGroup", + "api-version": "2021-07-01", + "galleryName": "myGalleryName" + }, + "responses": { + "200": { + "body": { + "properties": { + "description": "This is the gallery description.", + "identifier": { + "uniqueName": "{subscription-id}-MYGALLERYNAME" + }, + "provisioningState": "Succeeded", + "sharingProfile": { + "permissions": "Community", + "communityGalleryInfo": { + "publisherUri": "uri", + "publisherContact": "pir@microsoft.com", + "eula": "eula", + "publicNames": [ + "GalelryPublicName" + ], + "communityGalleryEnabled": true + } + }, + "sharingStatus": { + "aggregatedState": "Succeeded", + "summary": [ + { + "region": "westus", + "state": "Succeeded", + "details": "" + } + ] + } + }, + "location": "West US", + "name": "myGalleryName" + } + } + } +} diff --git a/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/gallery.json b/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/gallery.json index 8013adcd137c..3d938c713b70 100644 --- a/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/gallery.json +++ b/specification/compute/resource-manager/Microsoft.Compute/stable/2021-07-01/gallery.json @@ -104,6 +104,9 @@ }, "Create or update a simple gallery with soft deletion enabled.": { "$ref": "./examples/gallery/CreateOrUpdateASimpleGalleryWithSoftDeletionEnabled.json" + }, + "Create a community gallery.": { + "$ref": "./examples/gallery/CreateACommunityGallery.json" } } }, @@ -219,6 +222,9 @@ }, "Get a gallery with select permissions.": { "$ref": "./examples/gallery/GetAGalleryWithSelectPermissions.json" + }, + "Get a community gallery.": { + "$ref": "./examples/gallery/GetACommunityGallery.json" } } }, @@ -1706,6 +1712,9 @@ "Add sharing id to the sharing profile of a gallery.": { "$ref": "./examples/gallery/AddToSharingProfileInAGallery.json" }, + "share a gallery to community.": { + "$ref": "./examples/gallery/EnableACommunityGallery.json" + }, "reset sharing profile of a gallery.": { "$ref": "./examples/gallery/ResetSharingProfileInAGallery.json" } @@ -1770,6 +1779,10 @@ }, "softDeletePolicy": { "$ref": "#/definitions/SoftDeletePolicy" + }, + "sharingStatus": { + "readOnly": true, + "$ref": "#/definitions/SharingStatus" } }, "description": "Describes the properties of a Shared Image Gallery." @@ -1789,10 +1802,11 @@ "properties": { "permissions": { "type": "string", - "description": "This property allows you to specify the permission of sharing gallery.

Possible values are:

**Private**

**Groups**", + "description": "This property allows you to specify the permission of sharing gallery.

Possible values are:

**Private**

**Groups**

**Community** ", "enum": [ "Private", - "Groups" + "Groups", + "Community" ], "x-ms-enum": { "name": "GallerySharingPermissionTypes", @@ -1806,6 +1820,12 @@ "$ref": "#/definitions/SharingProfileGroup" }, "description": "A list of sharing profile groups." + }, + "communityGalleryInfo": { + "items": { + "$ref": "#/definitions/CommunityGalleryInfo" + }, + "description": "Information of community gallery if current gallery is shared to community." } } }, @@ -1814,7 +1834,7 @@ "properties": { "type": { "type": "string", - "description": "This property allows you to specify the type of sharing group.

Possible values are:

**Subscriptions**

**AADTenants**", + "description": "This property allows you to specify the type of sharing group.

Possible values are:

**Subscriptions**

**AADTenants** ", "enum": [ "Subscriptions", "AADTenants" @@ -1833,6 +1853,40 @@ } } }, + "CommunityGalleryInfo": { + "description": "Information of community gallery if current gallery is shared to community", + "properties": { + "publisherUri": { + "type": "string", + "description": "The link to the publisher website. Visible to all users." + }, + "publisherContact": { + "type": "string", + "description": "Community gallery publisher support email. The email address of the publisher. Visible to all users." + }, + "eula": { + "type": "string", + "description": "Community gallery publisher eula." + }, + "publicNamePrefix": { + "type": "string", + "description": "The prefix of the gallery name that will be displayed publicly. Visible to all users." + }, + "communityGalleryEnabled": { + "readOnly": true, + "type": "boolean", + "description": "Contains info about whether community gallery sharing is enabled." + }, + "publicNames": { + "readOnly": true, + "type": "array", + "items": { + "type": "string" + }, + "description": "Community gallery public name list." + } + } + }, "SoftDeletePolicy": { "type": "object", "properties": { @@ -1843,6 +1897,53 @@ }, "description": "Contains information about the soft deletion policy of the gallery." }, + "SharingStatus": { + "properties": { + "aggregatedState": { + "type": "string", + "$ref": "#/definitions/SharingState", + "description": "Aggregated sharing state of current gallery." + }, + "summary": { + "type": "array", + "items": { + "$ref": "#/definitions/RegionalSharingStatus" + }, + "description": "Summary of all regional sharing status." + } + }, + "description": "Sharing status of current gallery." + }, + "SharingState": { + "readOnly": true, + "type": "string", + "title": "The sharing state of the gallery.", + "description": "The sharing state of the gallery, which only appears in the response.", + "enum": [ + "Succeeded", + "InProgress", + "Failed", + "Unknown" + ] + }, + "RegionalSharingStatus": { + "description": "Gallery regional sharing status", + "properties": { + "region": { + "type": "string", + "description": "Region name" + }, + "state": { + "type": "string", + "$ref": "#/definitions/SharingState", + "description": "Gallery sharing state in current region" + }, + "details": { + "type": "string", + "description": "Details of gallery regional sharing failure." + } + } + }, "GalleryApplication": { "properties": { "properties": { @@ -2412,6 +2513,13 @@ "description": "Optional. Allows users to provide customer managed keys for encrypting the OS and data disks in the gallery artifact." }, "OSDiskImageEncryption": { + "properties": { + "securityProfile": { + "type": "object", + "$ref": "#/definitions/OSDiskImageSecurityProfile", + "description": "This property specifies the security profile of an OS disk image." + } + }, "allOf": [ { "$ref": "#/definitions/DiskImageEncryption" @@ -2419,6 +2527,28 @@ ], "description": "Contains encryption settings for an OS disk image." }, + "OSDiskImageSecurityProfile": { + "properties": { + "type": { + "type": "string", + "description": "all types of security profile", + "enum": [ + "EncryptedVMGuestStateOnlyWithPmk", + "EncryptedWithPmk", + "EncryptedWithCmk" + ], + "x-ms-enum": { + "name": "SecurityProfileType", + "modelAsString": false + } + }, + "secureVMDiskEncryptionSetId": { + "type": "string", + "description": "secure VM disk encryption set id" + } + }, + "description": "Contains security profile for an OS disk image." + }, "DataDiskImageEncryption": { "properties": { "lun": { @@ -2863,7 +2993,8 @@ "enum": [ "Add", "Remove", - "Reset" + "Reset", + "EnableCommunity" ], "x-ms-enum": { "name": "SharingUpdateOperationTypes",