From 476d2dd49f77137cdf3dc653933a7e1cfd628f1f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 25 Dec 2024 11:05:35 +0000 Subject: [PATCH] chore(deps): bump github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6 Bumps [github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6](https://github.com/Azure/azure-sdk-for-go) from 6.1.0 to 6.2.0. - [Release notes](https://github.com/Azure/azure-sdk-for-go/releases) - [Changelog](https://github.com/Azure/azure-sdk-for-go/blob/main/documentation/release.md) - [Commits](https://github.com/Azure/azure-sdk-for-go/compare/sdk/resourcemanager/compute/armcompute/v6.1.0...sdk/resourcemanager/compute/armcompute/v6.2.0) --- updated-dependencies: - dependency-name: github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 4 +- .../compute/armcompute/v6/CHANGELOG.md | 61 ++ .../compute/armcompute/v6/README.md | 6 +- .../compute/armcompute/v6/assets.json | 2 +- .../compute/armcompute/v6/autorest.md | 8 +- .../compute/armcompute/v6/ci.yml | 1 - .../compute/armcompute/v6/client_factory.go | 24 + .../v6/communitygalleries_client.go | 4 +- .../v6/communitygalleryimages_client.go | 8 +- .../communitygalleryimageversions_client.go | 8 +- .../compute/armcompute/v6/constants.go | 127 ++- .../compute/armcompute/v6/galleries_client.go | 30 +- .../v6/galleryapplications_client.go | 26 +- .../v6/galleryapplicationversions_client.go | 26 +- .../armcompute/v6/galleryimages_client.go | 26 +- .../v6/galleryimageversions_client.go | 26 +- ...galleryinvmaccesscontrolprofiles_client.go | 435 ++++++++ ...invmaccesscontrolprofileversions_client.go | 466 +++++++++ .../v6/gallerysharingprofile_client.go | 6 +- .../compute/armcompute/v6/models.go | 382 ++++++- .../compute/armcompute/v6/models_serde.go | 959 +++++++++++++++++- .../compute/armcompute/v6/options.go | 74 +- .../compute/armcompute/v6/responses.go | 65 ++ .../armcompute/v6/sharedgalleries_client.go | 8 +- .../v6/sharedgalleryimages_client.go | 8 +- .../v6/sharedgalleryimageversions_client.go | 8 +- .../v6/softdeletedresource_client.go | 122 +++ .../armcompute/v6/virtualmachines_client.go | 6 +- .../v6/virtualmachinescalesets_client.go | 6 +- .../v6/virtualmachinescalesetvms_client.go | 6 +- vendor/modules.txt | 2 +- 32 files changed, 2788 insertions(+), 154 deletions(-) create mode 100644 vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryinvmaccesscontrolprofiles_client.go create mode 100644 vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryinvmaccesscontrolprofileversions_client.go create mode 100644 vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/softdeletedresource_client.go diff --git a/go.mod b/go.mod index 36de16d084..da8f0369f7 100644 --- a/go.mod +++ b/go.mod @@ -7,7 +7,7 @@ godebug winsymlink=0 require ( github.com/Azure/azure-sdk-for-go v68.0.0+incompatible github.com/Azure/azure-sdk-for-go/sdk/azcore v1.16.0 - github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6 v6.1.0 + github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6 v6.2.0 github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/network/armnetwork/v6 v6.2.0 github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/resources/armresources v1.2.0 github.com/Azure/go-autorest/autorest v0.11.29 diff --git a/go.sum b/go.sum index dde9462b44..073d3ecbfb 100644 --- a/go.sum +++ b/go.sum @@ -13,8 +13,8 @@ github.com/Azure/azure-sdk-for-go/sdk/internal v1.10.0 h1:ywEEhmNahHBihViHepv3xP github.com/Azure/azure-sdk-for-go/sdk/internal v1.10.0/go.mod h1:iZDifYGJTIgIIkYRNWPENUnqx6bJ2xnSDFI2tjwZNuY= github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/authorization/armauthorization/v2 v2.2.0 h1:Hp+EScFOu9HeCbeW8WU2yQPJd4gGwhMgKxWe+G6jNzw= github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/authorization/armauthorization/v2 v2.2.0/go.mod h1:/pz8dyNQe+Ey3yBp/XuYz7oqX8YDNWVpPB0hH3XWfbc= -github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6 v6.1.0 h1:zDeQI/PaWztI2tcrGO/9RIMey9NvqYbnyttf/0P3QWM= -github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6 v6.1.0/go.mod h1:zflC9v4VfViJrSvcvplqws/yGXVbUEMZi/iHpZdSPWA= +github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6 v6.2.0 h1:JAebRMoc3vL+Nd97GBprHYHucO4+wlW+tNbBIumqJlk= +github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6 v6.2.0/go.mod h1:zflC9v4VfViJrSvcvplqws/yGXVbUEMZi/iHpZdSPWA= github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/containerregistry/armcontainerregistry v1.2.0 h1:DWlwvVV5r/Wy1561nZ3wrpI1/vDIBRY/Wd1HWaRBZWA= github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/containerregistry/armcontainerregistry v1.2.0/go.mod h1:E7ltexgRDmeJ0fJWv0D/HLwY2xbDdN+uv+X2uZtOx3w= github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/containerservice/armcontainerservice/v5 v5.0.0 h1:5n7dPVqsWfVKw+ZiEKSd3Kzu7gwBkbEBkeXb8rgaE9Q= diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/CHANGELOG.md b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/CHANGELOG.md index 041b302e2d..612bff10d6 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/CHANGELOG.md +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/CHANGELOG.md @@ -1,5 +1,66 @@ # Release History +## 6.2.0 (2024-12-27) +### Features Added + +- New value `StorageAccountTypePremiumV2LRS` added to enum type `StorageAccountType` +- New enum type `AccessControlRulesMode` with values `AccessControlRulesModeAudit`, `AccessControlRulesModeDisabled`, `AccessControlRulesModeEnforce` +- New enum type `EndpointAccess` with values `EndpointAccessAllow`, `EndpointAccessDeny` +- New enum type `EndpointTypes` with values `EndpointTypesIMDS`, `EndpointTypesWireServer` +- New enum type `GalleryApplicationScriptRebootBehavior` with values `GalleryApplicationScriptRebootBehaviorNone`, `GalleryApplicationScriptRebootBehaviorRerun` +- New enum type `SoftDeletedArtifactTypes` with values `SoftDeletedArtifactTypesImages` +- New enum type `ValidationStatus` with values `ValidationStatusFailed`, `ValidationStatusSucceeded`, `ValidationStatusUnknown` +- New function `*ClientFactory.NewGalleryInVMAccessControlProfileVersionsClient() *GalleryInVMAccessControlProfileVersionsClient` +- New function `*ClientFactory.NewGalleryInVMAccessControlProfilesClient() *GalleryInVMAccessControlProfilesClient` +- New function `*ClientFactory.NewSoftDeletedResourceClient() *SoftDeletedResourceClient` +- New function `NewGalleryInVMAccessControlProfileVersionsClient(string, azcore.TokenCredential, *arm.ClientOptions) (*GalleryInVMAccessControlProfileVersionsClient, error)` +- New function `*GalleryInVMAccessControlProfileVersionsClient.BeginCreateOrUpdate(context.Context, string, string, string, string, GalleryInVMAccessControlProfileVersion, *GalleryInVMAccessControlProfileVersionsClientBeginCreateOrUpdateOptions) (*runtime.Poller[GalleryInVMAccessControlProfileVersionsClientCreateOrUpdateResponse], error)` +- New function `*GalleryInVMAccessControlProfileVersionsClient.BeginDelete(context.Context, string, string, string, string, *GalleryInVMAccessControlProfileVersionsClientBeginDeleteOptions) (*runtime.Poller[GalleryInVMAccessControlProfileVersionsClientDeleteResponse], error)` +- New function `*GalleryInVMAccessControlProfileVersionsClient.Get(context.Context, string, string, string, string, *GalleryInVMAccessControlProfileVersionsClientGetOptions) (GalleryInVMAccessControlProfileVersionsClientGetResponse, error)` +- New function `*GalleryInVMAccessControlProfileVersionsClient.NewListByGalleryInVMAccessControlProfilePager(string, string, string, *GalleryInVMAccessControlProfileVersionsClientListByGalleryInVMAccessControlProfileOptions) *runtime.Pager[GalleryInVMAccessControlProfileVersionsClientListByGalleryInVMAccessControlProfileResponse]` +- New function `*GalleryInVMAccessControlProfileVersionsClient.BeginUpdate(context.Context, string, string, string, string, GalleryInVMAccessControlProfileVersionUpdate, *GalleryInVMAccessControlProfileVersionsClientBeginUpdateOptions) (*runtime.Poller[GalleryInVMAccessControlProfileVersionsClientUpdateResponse], error)` +- New function `NewGalleryInVMAccessControlProfilesClient(string, azcore.TokenCredential, *arm.ClientOptions) (*GalleryInVMAccessControlProfilesClient, error)` +- New function `*GalleryInVMAccessControlProfilesClient.BeginCreateOrUpdate(context.Context, string, string, string, GalleryInVMAccessControlProfile, *GalleryInVMAccessControlProfilesClientBeginCreateOrUpdateOptions) (*runtime.Poller[GalleryInVMAccessControlProfilesClientCreateOrUpdateResponse], error)` +- New function `*GalleryInVMAccessControlProfilesClient.BeginDelete(context.Context, string, string, string, *GalleryInVMAccessControlProfilesClientBeginDeleteOptions) (*runtime.Poller[GalleryInVMAccessControlProfilesClientDeleteResponse], error)` +- New function `*GalleryInVMAccessControlProfilesClient.Get(context.Context, string, string, string, *GalleryInVMAccessControlProfilesClientGetOptions) (GalleryInVMAccessControlProfilesClientGetResponse, error)` +- New function `*GalleryInVMAccessControlProfilesClient.NewListByGalleryPager(string, string, *GalleryInVMAccessControlProfilesClientListByGalleryOptions) *runtime.Pager[GalleryInVMAccessControlProfilesClientListByGalleryResponse]` +- New function `*GalleryInVMAccessControlProfilesClient.BeginUpdate(context.Context, string, string, string, GalleryInVMAccessControlProfileUpdate, *GalleryInVMAccessControlProfilesClientBeginUpdateOptions) (*runtime.Poller[GalleryInVMAccessControlProfilesClientUpdateResponse], error)` +- New function `NewSoftDeletedResourceClient(string, azcore.TokenCredential, *arm.ClientOptions) (*SoftDeletedResourceClient, error)` +- New function `*SoftDeletedResourceClient.NewListByArtifactNamePager(string, string, string, string, *SoftDeletedResourceClientListByArtifactNameOptions) *runtime.Pager[SoftDeletedResourceClientListByArtifactNameResponse]` +- New struct `AccessControlRules` +- New struct `AccessControlRulesIdentity` +- New struct `AccessControlRulesPrivilege` +- New struct `AccessControlRulesRole` +- New struct `AccessControlRulesRoleAssignment` +- New struct `AdditionalReplicaSet` +- New struct `ExecutedValidation` +- New struct `GalleryIdentity` +- New struct `GalleryInVMAccessControlProfile` +- New struct `GalleryInVMAccessControlProfileList` +- New struct `GalleryInVMAccessControlProfileProperties` +- New struct `GalleryInVMAccessControlProfileUpdate` +- New struct `GalleryInVMAccessControlProfileVersion` +- New struct `GalleryInVMAccessControlProfileVersionList` +- New struct `GalleryInVMAccessControlProfileVersionProperties` +- New struct `GalleryInVMAccessControlProfileVersionUpdate` +- New struct `GalleryResourceProfilePropertiesBase` +- New struct `GalleryResourceProfileVersionPropertiesBase` +- New struct `GallerySoftDeletedResource` +- New struct `GallerySoftDeletedResourceList` +- New struct `GallerySoftDeletedResourceProperties` +- New struct `PlatformAttribute` +- New struct `ValidationsProfile` +- New field `Identity` in struct `Gallery` +- New field `StartsAtVersion` in struct `GalleryImageFeature` +- New field `AllowUpdateImage` in struct `GalleryImageProperties` +- New field `Restore`, `ValidationsProfile` in struct `GalleryImageVersionProperties` +- New field `BlockDeletionBeforeEndOfLife` in struct `GalleryImageVersionSafetyProfile` +- New field `SecurityProfile` in struct `GalleryList` +- New field `Identity` in struct `GalleryUpdate` +- New field `AdditionalReplicaSets` in struct `TargetRegion` +- New field `ScriptBehaviorAfterReboot` in struct `UserArtifactSettings` + + ## 6.1.0 (2024-08-23) ### Features Added diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/README.md b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/README.md index b508c67ffe..869a19f3f4 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/README.md +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/README.md @@ -1,7 +1,5 @@ # Azure Compute Module for Go -[![PkgGoDev](https://pkg.go.dev/badge/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6)](https://pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6) - The `armcompute` module provides operations for working with Azure Compute. [Source code](https://github.com/Azure/azure-sdk-for-go/tree/main/sdk/resourcemanager/compute/armcompute) @@ -25,7 +23,7 @@ go get github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/ ## Authorization -When creating a client, you will need to provide a credential for authenticating with Azure Compute. The `azidentity` module provides facilities for various ways of authenticating with Azure including client/secret, certificate, managed identity, and more. +When creating a client, you will need to provide a credential for authenticating with Azure Compute. The `azidentity` module provides facilities for various ways of authenticating with Azure including client/secret, certificate, managed identity, and more. ```go cred, err := azidentity.NewDefaultAzureCredential(nil) @@ -54,7 +52,7 @@ clientFactory, err := armcompute.NewClientFactory(, cred, &opti ## Clients -A client groups a set of related APIs, providing access to its functionality. Create one or more clients to access the APIs you require using client factory. +A client groups a set of related APIs, providing access to its functionality. Create one or more clients to access the APIs you require using client factory. ```go client := clientFactory.NewAvailabilitySetsClient() diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/assets.json b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/assets.json index d7acbc3a71..3837e7e938 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/assets.json +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/assets.json @@ -2,5 +2,5 @@ "AssetsRepo": "Azure/azure-sdk-assets", "AssetsRepoPrefixPath": "go", "TagPrefix": "go/resourcemanager/compute/armcompute", - "Tag": "go/resourcemanager/compute/armcompute_35cebc37ab" + "Tag": "go/resourcemanager/compute/armcompute_4953449a2e" } diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/autorest.md b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/autorest.md index 073400edde..24453ed0df 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/autorest.md +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/autorest.md @@ -5,9 +5,9 @@ ``` yaml azure-arm: true require: -- https://github.com/Azure/azure-rest-api-specs/blob/c7b98b36e4023331545051284d8500adf98f02fe/specification/compute/resource-manager/readme.md -- https://github.com/Azure/azure-rest-api-specs/blob/c7b98b36e4023331545051284d8500adf98f02fe/specification/compute/resource-manager/readme.go.md +- https://github.com/Azure/azure-rest-api-specs/blob/069a65e8a6d1a6c0c58d9a9d97610b7103b6e8a5/specification/compute/resource-manager/readme.md +- https://github.com/Azure/azure-rest-api-specs/blob/069a65e8a6d1a6c0c58d9a9d97610b7103b6e8a5/specification/compute/resource-manager/readme.go.md license-header: MICROSOFT_MIT_NO_VERSION -module-version: 6.1.0 -tag: package-2024-07-01 +module-version: 6.2.0 +tag: package-2024-10-01 ``` diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/ci.yml b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/ci.yml index b805596c70..7ca73744ee 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/ci.yml +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/ci.yml @@ -27,4 +27,3 @@ extends: IncludeRelease: true ServiceDirectory: 'resourcemanager/compute/armcompute' UsePipelineProxy: false - UseFederatedAuth: true diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/client_factory.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/client_factory.go index dab27c87cb..e4b1178136 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/client_factory.go +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/client_factory.go @@ -213,6 +213,22 @@ func (c *ClientFactory) NewGalleryImagesClient() *GalleryImagesClient { } } +// NewGalleryInVMAccessControlProfileVersionsClient creates a new instance of GalleryInVMAccessControlProfileVersionsClient. +func (c *ClientFactory) NewGalleryInVMAccessControlProfileVersionsClient() *GalleryInVMAccessControlProfileVersionsClient { + return &GalleryInVMAccessControlProfileVersionsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } +} + +// NewGalleryInVMAccessControlProfilesClient creates a new instance of GalleryInVMAccessControlProfilesClient. +func (c *ClientFactory) NewGalleryInVMAccessControlProfilesClient() *GalleryInVMAccessControlProfilesClient { + return &GalleryInVMAccessControlProfilesClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } +} + // NewGallerySharingProfileClient creates a new instance of GallerySharingProfileClient. func (c *ClientFactory) NewGallerySharingProfileClient() *GallerySharingProfileClient { return &GallerySharingProfileClient{ @@ -316,6 +332,14 @@ func (c *ClientFactory) NewSnapshotsClient() *SnapshotsClient { } } +// NewSoftDeletedResourceClient creates a new instance of SoftDeletedResourceClient. +func (c *ClientFactory) NewSoftDeletedResourceClient() *SoftDeletedResourceClient { + return &SoftDeletedResourceClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } +} + // NewUsageClient creates a new instance of UsageClient. func (c *ClientFactory) NewUsageClient() *UsageClient { return &UsageClient{ diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/communitygalleries_client.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/communitygalleries_client.go index 431a26cdef..8ec49a6e65 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/communitygalleries_client.go +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/communitygalleries_client.go @@ -47,7 +47,7 @@ func NewCommunityGalleriesClient(subscriptionID string, credential azcore.TokenC // Get - Get a community gallery by gallery public name. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - location - Resource location. // - publicGalleryName - The public name of the community gallery. // - options - CommunityGalleriesClientGetOptions contains the optional parameters for the CommunityGalleriesClient.Get method. @@ -93,7 +93,7 @@ func (client *CommunityGalleriesClient) getCreateRequest(ctx context.Context, lo return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/communitygalleryimages_client.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/communitygalleryimages_client.go index 4ecc005caa..e802a6f687 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/communitygalleryimages_client.go +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/communitygalleryimages_client.go @@ -47,7 +47,7 @@ func NewCommunityGalleryImagesClient(subscriptionID string, credential azcore.To // Get - Get a community gallery image. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - location - Resource location. // - publicGalleryName - The public name of the community gallery. // - galleryImageName - The name of the community gallery image definition. @@ -99,7 +99,7 @@ func (client *CommunityGalleryImagesClient) getCreateRequest(ctx context.Context return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -116,7 +116,7 @@ func (client *CommunityGalleryImagesClient) getHandleResponse(resp *http.Respons // NewListPager - List community gallery images inside a gallery. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - location - Resource location. // - publicGalleryName - The public name of the community gallery. // - options - CommunityGalleryImagesClientListOptions contains the optional parameters for the CommunityGalleryImagesClient.NewListPager @@ -164,7 +164,7 @@ func (client *CommunityGalleryImagesClient) listCreateRequest(ctx context.Contex return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/communitygalleryimageversions_client.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/communitygalleryimageversions_client.go index e98cfa506c..6085550188 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/communitygalleryimageversions_client.go +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/communitygalleryimageversions_client.go @@ -47,7 +47,7 @@ func NewCommunityGalleryImageVersionsClient(subscriptionID string, credential az // Get - Get a community gallery image version. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - location - Resource location. // - publicGalleryName - The public name of the community gallery. // - galleryImageName - The name of the community gallery image definition. @@ -106,7 +106,7 @@ func (client *CommunityGalleryImageVersionsClient) getCreateRequest(ctx context. return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -123,7 +123,7 @@ func (client *CommunityGalleryImageVersionsClient) getHandleResponse(resp *http. // NewListPager - List community gallery image versions inside an image. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - location - Resource location. // - publicGalleryName - The public name of the community gallery. // - galleryImageName - The name of the community gallery image definition. @@ -176,7 +176,7 @@ func (client *CommunityGalleryImageVersionsClient) listCreateRequest(ctx context return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/constants.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/constants.go index b36ceb3938..fd148f9181 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/constants.go +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/constants.go @@ -10,9 +10,28 @@ package armcompute const ( moduleName = "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute" - moduleVersion = "v6.1.0" + moduleVersion = "v6.2.0" ) +// AccessControlRulesMode - This property allows you to specify whether the access control rules are in Audit mode, in Enforce +// mode or Disabled. Possible values are: 'Audit', 'Enforce' or 'Disabled'. +type AccessControlRulesMode string + +const ( + AccessControlRulesModeAudit AccessControlRulesMode = "Audit" + AccessControlRulesModeDisabled AccessControlRulesMode = "Disabled" + AccessControlRulesModeEnforce AccessControlRulesMode = "Enforce" +) + +// PossibleAccessControlRulesModeValues returns the possible values for the AccessControlRulesMode const type. +func PossibleAccessControlRulesModeValues() []AccessControlRulesMode { + return []AccessControlRulesMode{ + AccessControlRulesModeAudit, + AccessControlRulesModeDisabled, + AccessControlRulesModeEnforce, + } +} + type AccessLevel string const ( @@ -85,7 +104,7 @@ func PossibleAlternativeTypeValues() []AlternativeType { } } -// Architecture - The architecture of the image. Applicable to OS disks only. +// Architecture - CPU architecture supported by an OS disk. type Architecture string const ( @@ -497,8 +516,8 @@ func PossibleDiskDeleteOptionTypesValues() []DiskDeleteOptionTypes { // is applicable only for managed data disks. If a previous detachment attempt of the data disk did not complete due to an // unexpected failure from the virtual machine and the disk is still not released // then use force-detach as a last resort option to detach the disk forcibly from the VM. All writes might not have been flushed -// when using this detach behavior. This feature is still in preview mode. To -// force-detach a data disk update toBeDetached to 'true' along with setting detachOption: 'ForceDetach'. +// when using this detach behavior. To force-detach a data disk update +// toBeDetached to 'true' along with setting detachOption: 'ForceDetach'. type DiskDetachOptionTypes string const ( @@ -732,6 +751,40 @@ func PossibleEncryptionTypeValues() []EncryptionType { } } +// EndpointAccess - This property allows you to specify if the requests will be allowed to access the host endpoints. Possible +// values are: 'Allow', 'Deny'. +type EndpointAccess string + +const ( + EndpointAccessAllow EndpointAccess = "Allow" + EndpointAccessDeny EndpointAccess = "Deny" +) + +// PossibleEndpointAccessValues returns the possible values for the EndpointAccess const type. +func PossibleEndpointAccessValues() []EndpointAccess { + return []EndpointAccess{ + EndpointAccessAllow, + EndpointAccessDeny, + } +} + +// EndpointTypes - This property allows you to specify the Endpoint type for which this profile is defining the access control +// for. Possible values are: 'WireServer' or 'IMDS' +type EndpointTypes string + +const ( + EndpointTypesIMDS EndpointTypes = "IMDS" + EndpointTypesWireServer EndpointTypes = "WireServer" +) + +// PossibleEndpointTypesValues returns the possible values for the EndpointTypes const type. +func PossibleEndpointTypesValues() []EndpointTypes { + return []EndpointTypes{ + EndpointTypesIMDS, + EndpointTypesWireServer, + } +} + // ExecutionState - Script execution status. type ExecutionState string @@ -877,6 +930,23 @@ func PossibleGalleryApplicationCustomActionParameterTypeValues() []GalleryApplic } } +// GalleryApplicationScriptRebootBehavior - Optional. The action to be taken with regards to install/update/remove of the +// gallery application in the event of a reboot. +type GalleryApplicationScriptRebootBehavior string + +const ( + GalleryApplicationScriptRebootBehaviorNone GalleryApplicationScriptRebootBehavior = "None" + GalleryApplicationScriptRebootBehaviorRerun GalleryApplicationScriptRebootBehavior = "Rerun" +) + +// PossibleGalleryApplicationScriptRebootBehaviorValues returns the possible values for the GalleryApplicationScriptRebootBehavior const type. +func PossibleGalleryApplicationScriptRebootBehaviorValues() []GalleryApplicationScriptRebootBehavior { + return []GalleryApplicationScriptRebootBehavior{ + GalleryApplicationScriptRebootBehaviorNone, + GalleryApplicationScriptRebootBehaviorRerun, + } +} + type GalleryExpandParams string const ( @@ -1310,8 +1380,7 @@ func PossibleOperatingSystemTypeValues() []OperatingSystemType { } } -// OperatingSystemTypes - This property allows you to specify the supported type of the OS that application is built for. -// Possible values are: Windows, Linux. +// OperatingSystemTypes - The Operating System type. type OperatingSystemTypes string const ( @@ -1720,9 +1789,9 @@ func PossibleResourceIDOptionsForGetCapacityReservationGroupsValues() []Resource } } -// ResourceIdentityType - The type of identity used for the virtual machine scale set. The type 'SystemAssigned, UserAssigned' -// includes both an implicitly created identity and a set of user assigned identities. The type 'None' -// will remove any identities from the virtual machine scale set. +// ResourceIdentityType - The type of identity used for the gallery. The type 'SystemAssigned, UserAssigned' includes both +// an implicitly created identity and a set of user assigned identities. The type 'None' will remove all +// identities from the gallery. type ResourceIdentityType string const ( @@ -2074,6 +2143,20 @@ func PossibleSnapshotStorageAccountTypesValues() []SnapshotStorageAccountTypes { } } +// SoftDeletedArtifactTypes - artifact type of the soft-deleted resource +type SoftDeletedArtifactTypes string + +const ( + SoftDeletedArtifactTypesImages SoftDeletedArtifactTypes = "Images" +) + +// PossibleSoftDeletedArtifactTypesValues returns the possible values for the SoftDeletedArtifactTypes const type. +func PossibleSoftDeletedArtifactTypesValues() []SoftDeletedArtifactTypes { + return []SoftDeletedArtifactTypes{ + SoftDeletedArtifactTypesImages, + } +} + // StatusLevelTypes - The level code. type StatusLevelTypes string @@ -2096,15 +2179,17 @@ func PossibleStatusLevelTypesValues() []StatusLevelTypes { type StorageAccountType string const ( - StorageAccountTypePremiumLRS StorageAccountType = "Premium_LRS" - StorageAccountTypeStandardLRS StorageAccountType = "Standard_LRS" - StorageAccountTypeStandardZRS StorageAccountType = "Standard_ZRS" + StorageAccountTypePremiumLRS StorageAccountType = "Premium_LRS" + StorageAccountTypePremiumV2LRS StorageAccountType = "PremiumV2_LRS" + StorageAccountTypeStandardLRS StorageAccountType = "Standard_LRS" + StorageAccountTypeStandardZRS StorageAccountType = "Standard_ZRS" ) // PossibleStorageAccountTypeValues returns the possible values for the StorageAccountType const type. func PossibleStorageAccountTypeValues() []StorageAccountType { return []StorageAccountType{ StorageAccountTypePremiumLRS, + StorageAccountTypePremiumV2LRS, StorageAccountTypeStandardLRS, StorageAccountTypeStandardZRS, } @@ -2358,6 +2443,24 @@ func PossibleVMGuestPatchRebootStatusValues() []VMGuestPatchRebootStatus { } } +// ValidationStatus - This property specifies the status of the validationProfile of the image version. +type ValidationStatus string + +const ( + ValidationStatusFailed ValidationStatus = "Failed" + ValidationStatusSucceeded ValidationStatus = "Succeeded" + ValidationStatusUnknown ValidationStatus = "Unknown" +) + +// PossibleValidationStatusValues returns the possible values for the ValidationStatus const type. +func PossibleValidationStatusValues() []ValidationStatus { + return []ValidationStatus{ + ValidationStatusFailed, + ValidationStatusSucceeded, + ValidationStatusUnknown, + } +} + // VirtualMachineEvictionPolicyTypes - Specifies the eviction policy for the Azure Spot VM/VMSS type VirtualMachineEvictionPolicyTypes string diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleries_client.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleries_client.go index f24e730a63..17cd0a54fe 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleries_client.go +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleries_client.go @@ -47,7 +47,7 @@ func NewGalleriesClient(subscriptionID string, credential azcore.TokenCredential // BeginCreateOrUpdate - Create or update a Shared Image Gallery. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Image Gallery. The allowed characters are alphabets and numbers with dots and periods // allowed in the middle. The maximum length is 80 characters. @@ -74,7 +74,7 @@ func (client *GalleriesClient) BeginCreateOrUpdate(ctx context.Context, resource // CreateOrUpdate - Create or update a Shared Image Gallery. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 func (client *GalleriesClient) createOrUpdate(ctx context.Context, resourceGroupName string, galleryName string, gallery Gallery, options *GalleriesClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "GalleriesClient.BeginCreateOrUpdate" @@ -116,7 +116,7 @@ func (client *GalleriesClient) createOrUpdateCreateRequest(ctx context.Context, return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, gallery); err != nil { @@ -128,7 +128,7 @@ func (client *GalleriesClient) createOrUpdateCreateRequest(ctx context.Context, // BeginDelete - Delete a Shared Image Gallery. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Image Gallery to be deleted. // - options - GalleriesClientBeginDeleteOptions contains the optional parameters for the GalleriesClient.BeginDelete method. @@ -152,7 +152,7 @@ func (client *GalleriesClient) BeginDelete(ctx context.Context, resourceGroupNam // Delete - Delete a Shared Image Gallery. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 func (client *GalleriesClient) deleteOperation(ctx context.Context, resourceGroupName string, galleryName string, options *GalleriesClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "GalleriesClient.BeginDelete" @@ -194,7 +194,7 @@ func (client *GalleriesClient) deleteCreateRequest(ctx context.Context, resource return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -203,7 +203,7 @@ func (client *GalleriesClient) deleteCreateRequest(ctx context.Context, resource // Get - Retrieves information about a Shared Image Gallery. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Image Gallery. // - options - GalleriesClientGetOptions contains the optional parameters for the GalleriesClient.Get method. @@ -255,7 +255,7 @@ func (client *GalleriesClient) getCreateRequest(ctx context.Context, resourceGro if options != nil && options.Select != nil { reqQP.Set("$select", string(*options.Select)) } - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -272,7 +272,7 @@ func (client *GalleriesClient) getHandleResponse(resp *http.Response) (Galleries // NewListPager - List galleries under a subscription. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - options - GalleriesClientListOptions contains the optional parameters for the GalleriesClient.NewListPager method. func (client *GalleriesClient) NewListPager(options *GalleriesClientListOptions) *runtime.Pager[GalleriesClientListResponse] { return runtime.NewPager(runtime.PagingHandler[GalleriesClientListResponse]{ @@ -309,7 +309,7 @@ func (client *GalleriesClient) listCreateRequest(ctx context.Context, options *G return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -326,7 +326,7 @@ func (client *GalleriesClient) listHandleResponse(resp *http.Response) (Gallerie // NewListByResourceGroupPager - List galleries under a resource group. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - options - GalleriesClientListByResourceGroupOptions contains the optional parameters for the GalleriesClient.NewListByResourceGroupPager // method. @@ -369,7 +369,7 @@ func (client *GalleriesClient) listByResourceGroupCreateRequest(ctx context.Cont return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -387,7 +387,7 @@ func (client *GalleriesClient) listByResourceGroupHandleResponse(resp *http.Resp // BeginUpdate - Update a Shared Image Gallery. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Image Gallery. The allowed characters are alphabets and numbers with dots and periods // allowed in the middle. The maximum length is 80 characters. @@ -413,7 +413,7 @@ func (client *GalleriesClient) BeginUpdate(ctx context.Context, resourceGroupNam // Update - Update a Shared Image Gallery. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 func (client *GalleriesClient) update(ctx context.Context, resourceGroupName string, galleryName string, gallery GalleryUpdate, options *GalleriesClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "GalleriesClient.BeginUpdate" @@ -455,7 +455,7 @@ func (client *GalleriesClient) updateCreateRequest(ctx context.Context, resource return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, gallery); err != nil { diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryapplications_client.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryapplications_client.go index cd5d6f3ecf..5bd6ea34e1 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryapplications_client.go +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryapplications_client.go @@ -47,7 +47,7 @@ func NewGalleryApplicationsClient(subscriptionID string, credential azcore.Token // BeginCreateOrUpdate - Create or update a gallery Application Definition. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Application Gallery in which the Application Definition is to be created. // - galleryApplicationName - The name of the gallery Application Definition to be created or updated. The allowed characters @@ -76,7 +76,7 @@ func (client *GalleryApplicationsClient) BeginCreateOrUpdate(ctx context.Context // CreateOrUpdate - Create or update a gallery Application Definition. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 func (client *GalleryApplicationsClient) createOrUpdate(ctx context.Context, resourceGroupName string, galleryName string, galleryApplicationName string, galleryApplication GalleryApplication, options *GalleryApplicationsClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "GalleryApplicationsClient.BeginCreateOrUpdate" @@ -122,7 +122,7 @@ func (client *GalleryApplicationsClient) createOrUpdateCreateRequest(ctx context return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, galleryApplication); err != nil { @@ -134,7 +134,7 @@ func (client *GalleryApplicationsClient) createOrUpdateCreateRequest(ctx context // BeginDelete - Delete a gallery Application. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Application Gallery in which the Application Definition is to be deleted. // - galleryApplicationName - The name of the gallery Application Definition to be deleted. @@ -160,7 +160,7 @@ func (client *GalleryApplicationsClient) BeginDelete(ctx context.Context, resour // Delete - Delete a gallery Application. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 func (client *GalleryApplicationsClient) deleteOperation(ctx context.Context, resourceGroupName string, galleryName string, galleryApplicationName string, options *GalleryApplicationsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "GalleryApplicationsClient.BeginDelete" @@ -206,7 +206,7 @@ func (client *GalleryApplicationsClient) deleteCreateRequest(ctx context.Context return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -215,7 +215,7 @@ func (client *GalleryApplicationsClient) deleteCreateRequest(ctx context.Context // Get - Retrieves information about a gallery Application Definition. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Application Gallery from which the Application Definitions are to be retrieved. // - galleryApplicationName - The name of the gallery Application Definition to be retrieved. @@ -266,7 +266,7 @@ func (client *GalleryApplicationsClient) getCreateRequest(ctx context.Context, r return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -283,7 +283,7 @@ func (client *GalleryApplicationsClient) getHandleResponse(resp *http.Response) // NewListByGalleryPager - List gallery Application Definitions in a gallery. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Application Gallery from which Application Definitions are to be listed. // - options - GalleryApplicationsClientListByGalleryOptions contains the optional parameters for the GalleryApplicationsClient.NewListByGalleryPager @@ -331,7 +331,7 @@ func (client *GalleryApplicationsClient) listByGalleryCreateRequest(ctx context. return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -349,7 +349,7 @@ func (client *GalleryApplicationsClient) listByGalleryHandleResponse(resp *http. // BeginUpdate - Update a gallery Application Definition. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Application Gallery in which the Application Definition is to be updated. // - galleryApplicationName - The name of the gallery Application Definition to be updated. The allowed characters are alphabets @@ -378,7 +378,7 @@ func (client *GalleryApplicationsClient) BeginUpdate(ctx context.Context, resour // Update - Update a gallery Application Definition. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 func (client *GalleryApplicationsClient) update(ctx context.Context, resourceGroupName string, galleryName string, galleryApplicationName string, galleryApplication GalleryApplicationUpdate, options *GalleryApplicationsClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "GalleryApplicationsClient.BeginUpdate" @@ -424,7 +424,7 @@ func (client *GalleryApplicationsClient) updateCreateRequest(ctx context.Context return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, galleryApplication); err != nil { diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryapplicationversions_client.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryapplicationversions_client.go index 06571af3d4..4c1caa9295 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryapplicationversions_client.go +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryapplicationversions_client.go @@ -47,7 +47,7 @@ func NewGalleryApplicationVersionsClient(subscriptionID string, credential azcor // BeginCreateOrUpdate - Create or update a gallery Application Version. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Application Gallery in which the Application Definition resides. // - galleryApplicationName - The name of the gallery Application Definition in which the Application Version is to be created. @@ -77,7 +77,7 @@ func (client *GalleryApplicationVersionsClient) BeginCreateOrUpdate(ctx context. // CreateOrUpdate - Create or update a gallery Application Version. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 func (client *GalleryApplicationVersionsClient) createOrUpdate(ctx context.Context, resourceGroupName string, galleryName string, galleryApplicationName string, galleryApplicationVersionName string, galleryApplicationVersion GalleryApplicationVersion, options *GalleryApplicationVersionsClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "GalleryApplicationVersionsClient.BeginCreateOrUpdate" @@ -127,7 +127,7 @@ func (client *GalleryApplicationVersionsClient) createOrUpdateCreateRequest(ctx return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, galleryApplicationVersion); err != nil { @@ -139,7 +139,7 @@ func (client *GalleryApplicationVersionsClient) createOrUpdateCreateRequest(ctx // BeginDelete - Delete a gallery Application Version. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Application Gallery in which the Application Definition resides. // - galleryApplicationName - The name of the gallery Application Definition in which the Application Version resides. @@ -166,7 +166,7 @@ func (client *GalleryApplicationVersionsClient) BeginDelete(ctx context.Context, // Delete - Delete a gallery Application Version. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 func (client *GalleryApplicationVersionsClient) deleteOperation(ctx context.Context, resourceGroupName string, galleryName string, galleryApplicationName string, galleryApplicationVersionName string, options *GalleryApplicationVersionsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "GalleryApplicationVersionsClient.BeginDelete" @@ -216,7 +216,7 @@ func (client *GalleryApplicationVersionsClient) deleteCreateRequest(ctx context. return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -225,7 +225,7 @@ func (client *GalleryApplicationVersionsClient) deleteCreateRequest(ctx context. // Get - Retrieves information about a gallery Application Version. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Application Gallery in which the Application Definition resides. // - galleryApplicationName - The name of the gallery Application Definition in which the Application Version resides. @@ -285,7 +285,7 @@ func (client *GalleryApplicationVersionsClient) getCreateRequest(ctx context.Con if options != nil && options.Expand != nil { reqQP.Set("$expand", string(*options.Expand)) } - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -302,7 +302,7 @@ func (client *GalleryApplicationVersionsClient) getHandleResponse(resp *http.Res // NewListByGalleryApplicationPager - List gallery Application Versions in a gallery Application Definition. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Application Gallery in which the Application Definition resides. // - galleryApplicationName - The name of the Shared Application Gallery Application Definition from which the Application Versions @@ -356,7 +356,7 @@ func (client *GalleryApplicationVersionsClient) listByGalleryApplicationCreateRe return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -374,7 +374,7 @@ func (client *GalleryApplicationVersionsClient) listByGalleryApplicationHandleRe // BeginUpdate - Update a gallery Application Version. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Application Gallery in which the Application Definition resides. // - galleryApplicationName - The name of the gallery Application Definition in which the Application Version is to be updated. @@ -404,7 +404,7 @@ func (client *GalleryApplicationVersionsClient) BeginUpdate(ctx context.Context, // Update - Update a gallery Application Version. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 func (client *GalleryApplicationVersionsClient) update(ctx context.Context, resourceGroupName string, galleryName string, galleryApplicationName string, galleryApplicationVersionName string, galleryApplicationVersion GalleryApplicationVersionUpdate, options *GalleryApplicationVersionsClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "GalleryApplicationVersionsClient.BeginUpdate" @@ -454,7 +454,7 @@ func (client *GalleryApplicationVersionsClient) updateCreateRequest(ctx context. return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, galleryApplicationVersion); err != nil { diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryimages_client.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryimages_client.go index 8be1a5784a..a827811db5 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryimages_client.go +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryimages_client.go @@ -47,7 +47,7 @@ func NewGalleryImagesClient(subscriptionID string, credential azcore.TokenCreden // BeginCreateOrUpdate - Create or update a gallery image definition. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Image Gallery in which the Image Definition is to be created. // - galleryImageName - The name of the gallery image definition to be created or updated. The allowed characters are alphabets @@ -76,7 +76,7 @@ func (client *GalleryImagesClient) BeginCreateOrUpdate(ctx context.Context, reso // CreateOrUpdate - Create or update a gallery image definition. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 func (client *GalleryImagesClient) createOrUpdate(ctx context.Context, resourceGroupName string, galleryName string, galleryImageName string, galleryImage GalleryImage, options *GalleryImagesClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "GalleryImagesClient.BeginCreateOrUpdate" @@ -122,7 +122,7 @@ func (client *GalleryImagesClient) createOrUpdateCreateRequest(ctx context.Conte return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, galleryImage); err != nil { @@ -134,7 +134,7 @@ func (client *GalleryImagesClient) createOrUpdateCreateRequest(ctx context.Conte // BeginDelete - Delete a gallery image. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Image Gallery in which the Image Definition is to be deleted. // - galleryImageName - The name of the gallery image definition to be deleted. @@ -160,7 +160,7 @@ func (client *GalleryImagesClient) BeginDelete(ctx context.Context, resourceGrou // Delete - Delete a gallery image. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 func (client *GalleryImagesClient) deleteOperation(ctx context.Context, resourceGroupName string, galleryName string, galleryImageName string, options *GalleryImagesClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "GalleryImagesClient.BeginDelete" @@ -206,7 +206,7 @@ func (client *GalleryImagesClient) deleteCreateRequest(ctx context.Context, reso return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -215,7 +215,7 @@ func (client *GalleryImagesClient) deleteCreateRequest(ctx context.Context, reso // Get - Retrieves information about a gallery image definition. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Image Gallery from which the Image Definitions are to be retrieved. // - galleryImageName - The name of the gallery image definition to be retrieved. @@ -266,7 +266,7 @@ func (client *GalleryImagesClient) getCreateRequest(ctx context.Context, resourc return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -283,7 +283,7 @@ func (client *GalleryImagesClient) getHandleResponse(resp *http.Response) (Galle // NewListByGalleryPager - List gallery image definitions in a gallery. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Image Gallery from which Image Definitions are to be listed. // - options - GalleryImagesClientListByGalleryOptions contains the optional parameters for the GalleryImagesClient.NewListByGalleryPager @@ -331,7 +331,7 @@ func (client *GalleryImagesClient) listByGalleryCreateRequest(ctx context.Contex return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -349,7 +349,7 @@ func (client *GalleryImagesClient) listByGalleryHandleResponse(resp *http.Respon // BeginUpdate - Update a gallery image definition. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Image Gallery in which the Image Definition is to be updated. // - galleryImageName - The name of the gallery image definition to be updated. The allowed characters are alphabets and numbers @@ -377,7 +377,7 @@ func (client *GalleryImagesClient) BeginUpdate(ctx context.Context, resourceGrou // Update - Update a gallery image definition. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 func (client *GalleryImagesClient) update(ctx context.Context, resourceGroupName string, galleryName string, galleryImageName string, galleryImage GalleryImageUpdate, options *GalleryImagesClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "GalleryImagesClient.BeginUpdate" @@ -423,7 +423,7 @@ func (client *GalleryImagesClient) updateCreateRequest(ctx context.Context, reso return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, galleryImage); err != nil { diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryimageversions_client.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryimageversions_client.go index b16e42ed74..3bfb97ea9a 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryimageversions_client.go +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryimageversions_client.go @@ -47,7 +47,7 @@ func NewGalleryImageVersionsClient(subscriptionID string, credential azcore.Toke // BeginCreateOrUpdate - Create or update a gallery image version. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Image Gallery in which the Image Definition resides. // - galleryImageName - The name of the gallery image definition in which the Image Version is to be created. @@ -77,7 +77,7 @@ func (client *GalleryImageVersionsClient) BeginCreateOrUpdate(ctx context.Contex // CreateOrUpdate - Create or update a gallery image version. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 func (client *GalleryImageVersionsClient) createOrUpdate(ctx context.Context, resourceGroupName string, galleryName string, galleryImageName string, galleryImageVersionName string, galleryImageVersion GalleryImageVersion, options *GalleryImageVersionsClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "GalleryImageVersionsClient.BeginCreateOrUpdate" @@ -127,7 +127,7 @@ func (client *GalleryImageVersionsClient) createOrUpdateCreateRequest(ctx contex return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, galleryImageVersion); err != nil { @@ -139,7 +139,7 @@ func (client *GalleryImageVersionsClient) createOrUpdateCreateRequest(ctx contex // BeginDelete - Delete a gallery image version. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Image Gallery in which the Image Definition resides. // - galleryImageName - The name of the gallery image definition in which the Image Version resides. @@ -166,7 +166,7 @@ func (client *GalleryImageVersionsClient) BeginDelete(ctx context.Context, resou // Delete - Delete a gallery image version. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 func (client *GalleryImageVersionsClient) deleteOperation(ctx context.Context, resourceGroupName string, galleryName string, galleryImageName string, galleryImageVersionName string, options *GalleryImageVersionsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "GalleryImageVersionsClient.BeginDelete" @@ -216,7 +216,7 @@ func (client *GalleryImageVersionsClient) deleteCreateRequest(ctx context.Contex return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -225,7 +225,7 @@ func (client *GalleryImageVersionsClient) deleteCreateRequest(ctx context.Contex // Get - Retrieves information about a gallery image version. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Image Gallery in which the Image Definition resides. // - galleryImageName - The name of the gallery image definition in which the Image Version resides. @@ -285,7 +285,7 @@ func (client *GalleryImageVersionsClient) getCreateRequest(ctx context.Context, if options != nil && options.Expand != nil { reqQP.Set("$expand", string(*options.Expand)) } - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -302,7 +302,7 @@ func (client *GalleryImageVersionsClient) getHandleResponse(resp *http.Response) // NewListByGalleryImagePager - List gallery image versions in a gallery image definition. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Image Gallery in which the Image Definition resides. // - galleryImageName - The name of the Shared Image Gallery Image Definition from which the Image Versions are to be listed. @@ -355,7 +355,7 @@ func (client *GalleryImageVersionsClient) listByGalleryImageCreateRequest(ctx co return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -373,7 +373,7 @@ func (client *GalleryImageVersionsClient) listByGalleryImageHandleResponse(resp // BeginUpdate - Update a gallery image version. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Image Gallery in which the Image Definition resides. // - galleryImageName - The name of the gallery image definition in which the Image Version is to be updated. @@ -403,7 +403,7 @@ func (client *GalleryImageVersionsClient) BeginUpdate(ctx context.Context, resou // Update - Update a gallery image version. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 func (client *GalleryImageVersionsClient) update(ctx context.Context, resourceGroupName string, galleryName string, galleryImageName string, galleryImageVersionName string, galleryImageVersion GalleryImageVersionUpdate, options *GalleryImageVersionsClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "GalleryImageVersionsClient.BeginUpdate" @@ -453,7 +453,7 @@ func (client *GalleryImageVersionsClient) updateCreateRequest(ctx context.Contex return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, galleryImageVersion); err != nil { diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryinvmaccesscontrolprofiles_client.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryinvmaccesscontrolprofiles_client.go new file mode 100644 index 0000000000..240719d97b --- /dev/null +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryinvmaccesscontrolprofiles_client.go @@ -0,0 +1,435 @@ +//go:build go1.18 +// +build go1.18 + +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. See License.txt in the project root for license information. +// Code generated by Microsoft (R) AutoRest Code Generator. DO NOT EDIT. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +package armcompute + +import ( + "context" + "errors" + "github.com/Azure/azure-sdk-for-go/sdk/azcore" + "github.com/Azure/azure-sdk-for-go/sdk/azcore/arm" + "github.com/Azure/azure-sdk-for-go/sdk/azcore/policy" + "github.com/Azure/azure-sdk-for-go/sdk/azcore/runtime" + "net/http" + "net/url" + "strings" +) + +// GalleryInVMAccessControlProfilesClient contains the methods for the GalleryInVMAccessControlProfiles group. +// Don't use this type directly, use NewGalleryInVMAccessControlProfilesClient() instead. +type GalleryInVMAccessControlProfilesClient struct { + internal *arm.Client + subscriptionID string +} + +// NewGalleryInVMAccessControlProfilesClient creates a new instance of GalleryInVMAccessControlProfilesClient with the specified values. +// - subscriptionID - Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms +// part of the URI for every service call. +// - credential - used to authorize requests. Usually a credential from azidentity. +// - options - pass nil to accept the default values. +func NewGalleryInVMAccessControlProfilesClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*GalleryInVMAccessControlProfilesClient, error) { + cl, err := arm.NewClient(moduleName, moduleVersion, credential, options) + if err != nil { + return nil, err + } + client := &GalleryInVMAccessControlProfilesClient{ + subscriptionID: subscriptionID, + internal: cl, + } + return client, nil +} + +// BeginCreateOrUpdate - Create or update a gallery inVMAccessControlProfile. +// If the operation fails it returns an *azcore.ResponseError type. +// +// Generated from API version 2024-03-03 +// - resourceGroupName - The name of the resource group. +// - galleryName - The name of the Shared Image Gallery in which the InVMAccessControlProfile is to be created. +// - inVMAccessControlProfileName - The name of the gallery inVMAccessControlProfile to be created or updated. The allowed characters +// are alphabets and numbers with dots, dashes, and periods allowed in the middle. The maximum length is +// 80 characters. +// - galleryInVMAccessControlProfile - Parameters supplied to the create or update gallery inVMAccessControlProfile operation. +// - options - GalleryInVMAccessControlProfilesClientBeginCreateOrUpdateOptions contains the optional parameters for the GalleryInVMAccessControlProfilesClient.BeginCreateOrUpdate +// method. +func (client *GalleryInVMAccessControlProfilesClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, galleryInVMAccessControlProfile GalleryInVMAccessControlProfile, options *GalleryInVMAccessControlProfilesClientBeginCreateOrUpdateOptions) (*runtime.Poller[GalleryInVMAccessControlProfilesClientCreateOrUpdateResponse], error) { + if options == nil || options.ResumeToken == "" { + resp, err := client.createOrUpdate(ctx, resourceGroupName, galleryName, inVMAccessControlProfileName, galleryInVMAccessControlProfile, options) + if err != nil { + return nil, err + } + poller, err := runtime.NewPoller(resp, client.internal.Pipeline(), &runtime.NewPollerOptions[GalleryInVMAccessControlProfilesClientCreateOrUpdateResponse]{ + Tracer: client.internal.Tracer(), + }) + return poller, err + } else { + return runtime.NewPollerFromResumeToken(options.ResumeToken, client.internal.Pipeline(), &runtime.NewPollerFromResumeTokenOptions[GalleryInVMAccessControlProfilesClientCreateOrUpdateResponse]{ + Tracer: client.internal.Tracer(), + }) + } +} + +// CreateOrUpdate - Create or update a gallery inVMAccessControlProfile. +// If the operation fails it returns an *azcore.ResponseError type. +// +// Generated from API version 2024-03-03 +func (client *GalleryInVMAccessControlProfilesClient) createOrUpdate(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, galleryInVMAccessControlProfile GalleryInVMAccessControlProfile, options *GalleryInVMAccessControlProfilesClientBeginCreateOrUpdateOptions) (*http.Response, error) { + var err error + const operationName = "GalleryInVMAccessControlProfilesClient.BeginCreateOrUpdate" + ctx = context.WithValue(ctx, runtime.CtxAPINameKey{}, operationName) + ctx, endSpan := runtime.StartSpan(ctx, operationName, client.internal.Tracer(), nil) + defer func() { endSpan(err) }() + req, err := client.createOrUpdateCreateRequest(ctx, resourceGroupName, galleryName, inVMAccessControlProfileName, galleryInVMAccessControlProfile, options) + if err != nil { + return nil, err + } + httpResp, err := client.internal.Pipeline().Do(req) + if err != nil { + return nil, err + } + if !runtime.HasStatusCode(httpResp, http.StatusOK, http.StatusCreated) { + err = runtime.NewResponseError(httpResp) + return nil, err + } + return httpResp, nil +} + +// createOrUpdateCreateRequest creates the CreateOrUpdate request. +func (client *GalleryInVMAccessControlProfilesClient) createOrUpdateCreateRequest(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, galleryInVMAccessControlProfile GalleryInVMAccessControlProfile, options *GalleryInVMAccessControlProfilesClientBeginCreateOrUpdateOptions) (*policy.Request, error) { + urlPath := "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/galleries/{galleryName}/inVMAccessControlProfiles/{inVMAccessControlProfileName}" + if client.subscriptionID == "" { + return nil, errors.New("parameter client.subscriptionID cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{subscriptionId}", url.PathEscape(client.subscriptionID)) + if resourceGroupName == "" { + return nil, errors.New("parameter resourceGroupName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{resourceGroupName}", url.PathEscape(resourceGroupName)) + if galleryName == "" { + return nil, errors.New("parameter galleryName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{galleryName}", url.PathEscape(galleryName)) + if inVMAccessControlProfileName == "" { + return nil, errors.New("parameter inVMAccessControlProfileName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{inVMAccessControlProfileName}", url.PathEscape(inVMAccessControlProfileName)) + req, err := runtime.NewRequest(ctx, http.MethodPut, runtime.JoinPaths(client.internal.Endpoint(), urlPath)) + if err != nil { + return nil, err + } + reqQP := req.Raw().URL.Query() + reqQP.Set("api-version", "2024-03-03") + req.Raw().URL.RawQuery = reqQP.Encode() + req.Raw().Header["Accept"] = []string{"application/json"} + if err := runtime.MarshalAsJSON(req, galleryInVMAccessControlProfile); err != nil { + return nil, err + } + return req, nil +} + +// BeginDelete - Delete a gallery inVMAccessControlProfile. +// If the operation fails it returns an *azcore.ResponseError type. +// +// Generated from API version 2024-03-03 +// - resourceGroupName - The name of the resource group. +// - galleryName - he name of the Shared Image Gallery in which the InVMAccessControlProfile resides. +// - inVMAccessControlProfileName - The name of the gallery inVMAccessControlProfile to be deleted. +// - options - GalleryInVMAccessControlProfilesClientBeginDeleteOptions contains the optional parameters for the GalleryInVMAccessControlProfilesClient.BeginDelete +// method. +func (client *GalleryInVMAccessControlProfilesClient) BeginDelete(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, options *GalleryInVMAccessControlProfilesClientBeginDeleteOptions) (*runtime.Poller[GalleryInVMAccessControlProfilesClientDeleteResponse], error) { + if options == nil || options.ResumeToken == "" { + resp, err := client.deleteOperation(ctx, resourceGroupName, galleryName, inVMAccessControlProfileName, options) + if err != nil { + return nil, err + } + poller, err := runtime.NewPoller(resp, client.internal.Pipeline(), &runtime.NewPollerOptions[GalleryInVMAccessControlProfilesClientDeleteResponse]{ + Tracer: client.internal.Tracer(), + }) + return poller, err + } else { + return runtime.NewPollerFromResumeToken(options.ResumeToken, client.internal.Pipeline(), &runtime.NewPollerFromResumeTokenOptions[GalleryInVMAccessControlProfilesClientDeleteResponse]{ + Tracer: client.internal.Tracer(), + }) + } +} + +// Delete - Delete a gallery inVMAccessControlProfile. +// If the operation fails it returns an *azcore.ResponseError type. +// +// Generated from API version 2024-03-03 +func (client *GalleryInVMAccessControlProfilesClient) deleteOperation(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, options *GalleryInVMAccessControlProfilesClientBeginDeleteOptions) (*http.Response, error) { + var err error + const operationName = "GalleryInVMAccessControlProfilesClient.BeginDelete" + ctx = context.WithValue(ctx, runtime.CtxAPINameKey{}, operationName) + ctx, endSpan := runtime.StartSpan(ctx, operationName, client.internal.Tracer(), nil) + defer func() { endSpan(err) }() + req, err := client.deleteCreateRequest(ctx, resourceGroupName, galleryName, inVMAccessControlProfileName, options) + if err != nil { + return nil, err + } + httpResp, err := client.internal.Pipeline().Do(req) + if err != nil { + return nil, err + } + if !runtime.HasStatusCode(httpResp, http.StatusAccepted, http.StatusNoContent) { + err = runtime.NewResponseError(httpResp) + return nil, err + } + return httpResp, nil +} + +// deleteCreateRequest creates the Delete request. +func (client *GalleryInVMAccessControlProfilesClient) deleteCreateRequest(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, options *GalleryInVMAccessControlProfilesClientBeginDeleteOptions) (*policy.Request, error) { + urlPath := "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/galleries/{galleryName}/inVMAccessControlProfiles/{inVMAccessControlProfileName}" + if client.subscriptionID == "" { + return nil, errors.New("parameter client.subscriptionID cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{subscriptionId}", url.PathEscape(client.subscriptionID)) + if resourceGroupName == "" { + return nil, errors.New("parameter resourceGroupName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{resourceGroupName}", url.PathEscape(resourceGroupName)) + if galleryName == "" { + return nil, errors.New("parameter galleryName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{galleryName}", url.PathEscape(galleryName)) + if inVMAccessControlProfileName == "" { + return nil, errors.New("parameter inVMAccessControlProfileName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{inVMAccessControlProfileName}", url.PathEscape(inVMAccessControlProfileName)) + req, err := runtime.NewRequest(ctx, http.MethodDelete, runtime.JoinPaths(client.internal.Endpoint(), urlPath)) + if err != nil { + return nil, err + } + reqQP := req.Raw().URL.Query() + reqQP.Set("api-version", "2024-03-03") + req.Raw().URL.RawQuery = reqQP.Encode() + req.Raw().Header["Accept"] = []string{"application/json"} + return req, nil +} + +// Get - Retrieves information about a gallery inVMAccessControlProfile. +// If the operation fails it returns an *azcore.ResponseError type. +// +// Generated from API version 2024-03-03 +// - resourceGroupName - The name of the resource group. +// - galleryName - The name of the Shared Image Gallery from which the InVMAccessControlProfiles are to be retrieved. +// - inVMAccessControlProfileName - The name of the gallery inVMAccessControlProfile to be retrieved. +// - options - GalleryInVMAccessControlProfilesClientGetOptions contains the optional parameters for the GalleryInVMAccessControlProfilesClient.Get +// method. +func (client *GalleryInVMAccessControlProfilesClient) Get(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, options *GalleryInVMAccessControlProfilesClientGetOptions) (GalleryInVMAccessControlProfilesClientGetResponse, error) { + var err error + const operationName = "GalleryInVMAccessControlProfilesClient.Get" + ctx = context.WithValue(ctx, runtime.CtxAPINameKey{}, operationName) + ctx, endSpan := runtime.StartSpan(ctx, operationName, client.internal.Tracer(), nil) + defer func() { endSpan(err) }() + req, err := client.getCreateRequest(ctx, resourceGroupName, galleryName, inVMAccessControlProfileName, options) + if err != nil { + return GalleryInVMAccessControlProfilesClientGetResponse{}, err + } + httpResp, err := client.internal.Pipeline().Do(req) + if err != nil { + return GalleryInVMAccessControlProfilesClientGetResponse{}, err + } + if !runtime.HasStatusCode(httpResp, http.StatusOK) { + err = runtime.NewResponseError(httpResp) + return GalleryInVMAccessControlProfilesClientGetResponse{}, err + } + resp, err := client.getHandleResponse(httpResp) + return resp, err +} + +// getCreateRequest creates the Get request. +func (client *GalleryInVMAccessControlProfilesClient) getCreateRequest(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, options *GalleryInVMAccessControlProfilesClientGetOptions) (*policy.Request, error) { + urlPath := "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/galleries/{galleryName}/inVMAccessControlProfiles/{inVMAccessControlProfileName}" + if client.subscriptionID == "" { + return nil, errors.New("parameter client.subscriptionID cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{subscriptionId}", url.PathEscape(client.subscriptionID)) + if resourceGroupName == "" { + return nil, errors.New("parameter resourceGroupName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{resourceGroupName}", url.PathEscape(resourceGroupName)) + if galleryName == "" { + return nil, errors.New("parameter galleryName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{galleryName}", url.PathEscape(galleryName)) + if inVMAccessControlProfileName == "" { + return nil, errors.New("parameter inVMAccessControlProfileName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{inVMAccessControlProfileName}", url.PathEscape(inVMAccessControlProfileName)) + req, err := runtime.NewRequest(ctx, http.MethodGet, runtime.JoinPaths(client.internal.Endpoint(), urlPath)) + if err != nil { + return nil, err + } + reqQP := req.Raw().URL.Query() + reqQP.Set("api-version", "2024-03-03") + req.Raw().URL.RawQuery = reqQP.Encode() + req.Raw().Header["Accept"] = []string{"application/json"} + return req, nil +} + +// getHandleResponse handles the Get response. +func (client *GalleryInVMAccessControlProfilesClient) getHandleResponse(resp *http.Response) (GalleryInVMAccessControlProfilesClientGetResponse, error) { + result := GalleryInVMAccessControlProfilesClientGetResponse{} + if err := runtime.UnmarshalAsJSON(resp, &result.GalleryInVMAccessControlProfile); err != nil { + return GalleryInVMAccessControlProfilesClientGetResponse{}, err + } + return result, nil +} + +// NewListByGalleryPager - List gallery inVMAccessControlProfiles in a gallery. +// +// Generated from API version 2024-03-03 +// - resourceGroupName - The name of the resource group. +// - galleryName - The name of the Shared Image Gallery from which the InVMAccessControlProfiles are to be listed. +// - options - GalleryInVMAccessControlProfilesClientListByGalleryOptions contains the optional parameters for the GalleryInVMAccessControlProfilesClient.NewListByGalleryPager +// method. +func (client *GalleryInVMAccessControlProfilesClient) NewListByGalleryPager(resourceGroupName string, galleryName string, options *GalleryInVMAccessControlProfilesClientListByGalleryOptions) *runtime.Pager[GalleryInVMAccessControlProfilesClientListByGalleryResponse] { + return runtime.NewPager(runtime.PagingHandler[GalleryInVMAccessControlProfilesClientListByGalleryResponse]{ + More: func(page GalleryInVMAccessControlProfilesClientListByGalleryResponse) bool { + return page.NextLink != nil && len(*page.NextLink) > 0 + }, + Fetcher: func(ctx context.Context, page *GalleryInVMAccessControlProfilesClientListByGalleryResponse) (GalleryInVMAccessControlProfilesClientListByGalleryResponse, error) { + ctx = context.WithValue(ctx, runtime.CtxAPINameKey{}, "GalleryInVMAccessControlProfilesClient.NewListByGalleryPager") + nextLink := "" + if page != nil { + nextLink = *page.NextLink + } + resp, err := runtime.FetcherForNextLink(ctx, client.internal.Pipeline(), nextLink, func(ctx context.Context) (*policy.Request, error) { + return client.listByGalleryCreateRequest(ctx, resourceGroupName, galleryName, options) + }, nil) + if err != nil { + return GalleryInVMAccessControlProfilesClientListByGalleryResponse{}, err + } + return client.listByGalleryHandleResponse(resp) + }, + Tracer: client.internal.Tracer(), + }) +} + +// listByGalleryCreateRequest creates the ListByGallery request. +func (client *GalleryInVMAccessControlProfilesClient) listByGalleryCreateRequest(ctx context.Context, resourceGroupName string, galleryName string, options *GalleryInVMAccessControlProfilesClientListByGalleryOptions) (*policy.Request, error) { + urlPath := "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/galleries/{galleryName}/inVMAccessControlProfiles" + if client.subscriptionID == "" { + return nil, errors.New("parameter client.subscriptionID cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{subscriptionId}", url.PathEscape(client.subscriptionID)) + if resourceGroupName == "" { + return nil, errors.New("parameter resourceGroupName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{resourceGroupName}", url.PathEscape(resourceGroupName)) + if galleryName == "" { + return nil, errors.New("parameter galleryName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{galleryName}", url.PathEscape(galleryName)) + req, err := runtime.NewRequest(ctx, http.MethodGet, runtime.JoinPaths(client.internal.Endpoint(), urlPath)) + if err != nil { + return nil, err + } + reqQP := req.Raw().URL.Query() + reqQP.Set("api-version", "2024-03-03") + req.Raw().URL.RawQuery = reqQP.Encode() + req.Raw().Header["Accept"] = []string{"application/json"} + return req, nil +} + +// listByGalleryHandleResponse handles the ListByGallery response. +func (client *GalleryInVMAccessControlProfilesClient) listByGalleryHandleResponse(resp *http.Response) (GalleryInVMAccessControlProfilesClientListByGalleryResponse, error) { + result := GalleryInVMAccessControlProfilesClientListByGalleryResponse{} + if err := runtime.UnmarshalAsJSON(resp, &result.GalleryInVMAccessControlProfileList); err != nil { + return GalleryInVMAccessControlProfilesClientListByGalleryResponse{}, err + } + return result, nil +} + +// BeginUpdate - Update a gallery inVMAccessControlProfile. +// If the operation fails it returns an *azcore.ResponseError type. +// +// Generated from API version 2024-03-03 +// - resourceGroupName - The name of the resource group. +// - galleryName - The name of the Shared Image Gallery in which the InVMAccessControlProfile is to be updated. +// - inVMAccessControlProfileName - The name of the gallery inVMAccessControlProfile to be updated. The allowed characters are +// alphabets and numbers with dots, dashes, and periods allowed in the middle. The maximum length is 80 +// characters. +// - galleryInVMAccessControlProfile - Parameters supplied to the update gallery inVMAccessControlProfile operation. +// - options - GalleryInVMAccessControlProfilesClientBeginUpdateOptions contains the optional parameters for the GalleryInVMAccessControlProfilesClient.BeginUpdate +// method. +func (client *GalleryInVMAccessControlProfilesClient) BeginUpdate(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, galleryInVMAccessControlProfile GalleryInVMAccessControlProfileUpdate, options *GalleryInVMAccessControlProfilesClientBeginUpdateOptions) (*runtime.Poller[GalleryInVMAccessControlProfilesClientUpdateResponse], error) { + if options == nil || options.ResumeToken == "" { + resp, err := client.update(ctx, resourceGroupName, galleryName, inVMAccessControlProfileName, galleryInVMAccessControlProfile, options) + if err != nil { + return nil, err + } + poller, err := runtime.NewPoller(resp, client.internal.Pipeline(), &runtime.NewPollerOptions[GalleryInVMAccessControlProfilesClientUpdateResponse]{ + Tracer: client.internal.Tracer(), + }) + return poller, err + } else { + return runtime.NewPollerFromResumeToken(options.ResumeToken, client.internal.Pipeline(), &runtime.NewPollerFromResumeTokenOptions[GalleryInVMAccessControlProfilesClientUpdateResponse]{ + Tracer: client.internal.Tracer(), + }) + } +} + +// Update - Update a gallery inVMAccessControlProfile. +// If the operation fails it returns an *azcore.ResponseError type. +// +// Generated from API version 2024-03-03 +func (client *GalleryInVMAccessControlProfilesClient) update(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, galleryInVMAccessControlProfile GalleryInVMAccessControlProfileUpdate, options *GalleryInVMAccessControlProfilesClientBeginUpdateOptions) (*http.Response, error) { + var err error + const operationName = "GalleryInVMAccessControlProfilesClient.BeginUpdate" + ctx = context.WithValue(ctx, runtime.CtxAPINameKey{}, operationName) + ctx, endSpan := runtime.StartSpan(ctx, operationName, client.internal.Tracer(), nil) + defer func() { endSpan(err) }() + req, err := client.updateCreateRequest(ctx, resourceGroupName, galleryName, inVMAccessControlProfileName, galleryInVMAccessControlProfile, options) + if err != nil { + return nil, err + } + httpResp, err := client.internal.Pipeline().Do(req) + if err != nil { + return nil, err + } + if !runtime.HasStatusCode(httpResp, http.StatusOK) { + err = runtime.NewResponseError(httpResp) + return nil, err + } + return httpResp, nil +} + +// updateCreateRequest creates the Update request. +func (client *GalleryInVMAccessControlProfilesClient) updateCreateRequest(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, galleryInVMAccessControlProfile GalleryInVMAccessControlProfileUpdate, options *GalleryInVMAccessControlProfilesClientBeginUpdateOptions) (*policy.Request, error) { + urlPath := "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/galleries/{galleryName}/inVMAccessControlProfiles/{inVMAccessControlProfileName}" + if client.subscriptionID == "" { + return nil, errors.New("parameter client.subscriptionID cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{subscriptionId}", url.PathEscape(client.subscriptionID)) + if resourceGroupName == "" { + return nil, errors.New("parameter resourceGroupName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{resourceGroupName}", url.PathEscape(resourceGroupName)) + if galleryName == "" { + return nil, errors.New("parameter galleryName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{galleryName}", url.PathEscape(galleryName)) + if inVMAccessControlProfileName == "" { + return nil, errors.New("parameter inVMAccessControlProfileName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{inVMAccessControlProfileName}", url.PathEscape(inVMAccessControlProfileName)) + req, err := runtime.NewRequest(ctx, http.MethodPatch, runtime.JoinPaths(client.internal.Endpoint(), urlPath)) + if err != nil { + return nil, err + } + reqQP := req.Raw().URL.Query() + reqQP.Set("api-version", "2024-03-03") + req.Raw().URL.RawQuery = reqQP.Encode() + req.Raw().Header["Accept"] = []string{"application/json"} + if err := runtime.MarshalAsJSON(req, galleryInVMAccessControlProfile); err != nil { + return nil, err + } + return req, nil +} diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryinvmaccesscontrolprofileversions_client.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryinvmaccesscontrolprofileversions_client.go new file mode 100644 index 0000000000..ae9c060642 --- /dev/null +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/galleryinvmaccesscontrolprofileversions_client.go @@ -0,0 +1,466 @@ +//go:build go1.18 +// +build go1.18 + +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. See License.txt in the project root for license information. +// Code generated by Microsoft (R) AutoRest Code Generator. DO NOT EDIT. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +package armcompute + +import ( + "context" + "errors" + "github.com/Azure/azure-sdk-for-go/sdk/azcore" + "github.com/Azure/azure-sdk-for-go/sdk/azcore/arm" + "github.com/Azure/azure-sdk-for-go/sdk/azcore/policy" + "github.com/Azure/azure-sdk-for-go/sdk/azcore/runtime" + "net/http" + "net/url" + "strings" +) + +// GalleryInVMAccessControlProfileVersionsClient contains the methods for the GalleryInVMAccessControlProfileVersions group. +// Don't use this type directly, use NewGalleryInVMAccessControlProfileVersionsClient() instead. +type GalleryInVMAccessControlProfileVersionsClient struct { + internal *arm.Client + subscriptionID string +} + +// NewGalleryInVMAccessControlProfileVersionsClient creates a new instance of GalleryInVMAccessControlProfileVersionsClient with the specified values. +// - subscriptionID - Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms +// part of the URI for every service call. +// - credential - used to authorize requests. Usually a credential from azidentity. +// - options - pass nil to accept the default values. +func NewGalleryInVMAccessControlProfileVersionsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*GalleryInVMAccessControlProfileVersionsClient, error) { + cl, err := arm.NewClient(moduleName, moduleVersion, credential, options) + if err != nil { + return nil, err + } + client := &GalleryInVMAccessControlProfileVersionsClient{ + subscriptionID: subscriptionID, + internal: cl, + } + return client, nil +} + +// BeginCreateOrUpdate - Create or update a gallery inVMAccessControlProfile version. +// If the operation fails it returns an *azcore.ResponseError type. +// +// Generated from API version 2024-03-03 +// - resourceGroupName - The name of the resource group. +// - galleryName - The name of the Shared Image Gallery in which the inVMAccessControlProfile resides. +// - inVMAccessControlProfileName - The name of the gallery inVMAccessControlProfile in which the inVMAccessControlProfile version +// is to be created. +// - inVMAccessControlProfileVersionName - The name of the gallery inVMAccessControlProfile version to be created. Needs to +// follow semantic version name pattern: The allowed characters are digit and period. Digits must be within the range of a +// 32-bit integer. Format: .. +// - galleryInVMAccessControlProfileVersion - Parameters supplied to the create or update gallery inVMAccessControlProfile version +// operation. +// - options - GalleryInVMAccessControlProfileVersionsClientBeginCreateOrUpdateOptions contains the optional parameters for +// the GalleryInVMAccessControlProfileVersionsClient.BeginCreateOrUpdate method. +func (client *GalleryInVMAccessControlProfileVersionsClient) BeginCreateOrUpdate(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, inVMAccessControlProfileVersionName string, galleryInVMAccessControlProfileVersion GalleryInVMAccessControlProfileVersion, options *GalleryInVMAccessControlProfileVersionsClientBeginCreateOrUpdateOptions) (*runtime.Poller[GalleryInVMAccessControlProfileVersionsClientCreateOrUpdateResponse], error) { + if options == nil || options.ResumeToken == "" { + resp, err := client.createOrUpdate(ctx, resourceGroupName, galleryName, inVMAccessControlProfileName, inVMAccessControlProfileVersionName, galleryInVMAccessControlProfileVersion, options) + if err != nil { + return nil, err + } + poller, err := runtime.NewPoller(resp, client.internal.Pipeline(), &runtime.NewPollerOptions[GalleryInVMAccessControlProfileVersionsClientCreateOrUpdateResponse]{ + Tracer: client.internal.Tracer(), + }) + return poller, err + } else { + return runtime.NewPollerFromResumeToken(options.ResumeToken, client.internal.Pipeline(), &runtime.NewPollerFromResumeTokenOptions[GalleryInVMAccessControlProfileVersionsClientCreateOrUpdateResponse]{ + Tracer: client.internal.Tracer(), + }) + } +} + +// CreateOrUpdate - Create or update a gallery inVMAccessControlProfile version. +// If the operation fails it returns an *azcore.ResponseError type. +// +// Generated from API version 2024-03-03 +func (client *GalleryInVMAccessControlProfileVersionsClient) createOrUpdate(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, inVMAccessControlProfileVersionName string, galleryInVMAccessControlProfileVersion GalleryInVMAccessControlProfileVersion, options *GalleryInVMAccessControlProfileVersionsClientBeginCreateOrUpdateOptions) (*http.Response, error) { + var err error + const operationName = "GalleryInVMAccessControlProfileVersionsClient.BeginCreateOrUpdate" + ctx = context.WithValue(ctx, runtime.CtxAPINameKey{}, operationName) + ctx, endSpan := runtime.StartSpan(ctx, operationName, client.internal.Tracer(), nil) + defer func() { endSpan(err) }() + req, err := client.createOrUpdateCreateRequest(ctx, resourceGroupName, galleryName, inVMAccessControlProfileName, inVMAccessControlProfileVersionName, galleryInVMAccessControlProfileVersion, options) + if err != nil { + return nil, err + } + httpResp, err := client.internal.Pipeline().Do(req) + if err != nil { + return nil, err + } + if !runtime.HasStatusCode(httpResp, http.StatusOK, http.StatusCreated) { + err = runtime.NewResponseError(httpResp) + return nil, err + } + return httpResp, nil +} + +// createOrUpdateCreateRequest creates the CreateOrUpdate request. +func (client *GalleryInVMAccessControlProfileVersionsClient) createOrUpdateCreateRequest(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, inVMAccessControlProfileVersionName string, galleryInVMAccessControlProfileVersion GalleryInVMAccessControlProfileVersion, options *GalleryInVMAccessControlProfileVersionsClientBeginCreateOrUpdateOptions) (*policy.Request, error) { + urlPath := "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/galleries/{galleryName}/inVMAccessControlProfiles/{inVMAccessControlProfileName}/versions/{inVMAccessControlProfileVersionName}" + if client.subscriptionID == "" { + return nil, errors.New("parameter client.subscriptionID cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{subscriptionId}", url.PathEscape(client.subscriptionID)) + if resourceGroupName == "" { + return nil, errors.New("parameter resourceGroupName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{resourceGroupName}", url.PathEscape(resourceGroupName)) + if galleryName == "" { + return nil, errors.New("parameter galleryName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{galleryName}", url.PathEscape(galleryName)) + if inVMAccessControlProfileName == "" { + return nil, errors.New("parameter inVMAccessControlProfileName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{inVMAccessControlProfileName}", url.PathEscape(inVMAccessControlProfileName)) + if inVMAccessControlProfileVersionName == "" { + return nil, errors.New("parameter inVMAccessControlProfileVersionName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{inVMAccessControlProfileVersionName}", url.PathEscape(inVMAccessControlProfileVersionName)) + req, err := runtime.NewRequest(ctx, http.MethodPut, runtime.JoinPaths(client.internal.Endpoint(), urlPath)) + if err != nil { + return nil, err + } + reqQP := req.Raw().URL.Query() + reqQP.Set("api-version", "2024-03-03") + req.Raw().URL.RawQuery = reqQP.Encode() + req.Raw().Header["Accept"] = []string{"application/json"} + if err := runtime.MarshalAsJSON(req, galleryInVMAccessControlProfileVersion); err != nil { + return nil, err + } + return req, nil +} + +// BeginDelete - Delete a gallery inVMAccessControlProfile version. +// If the operation fails it returns an *azcore.ResponseError type. +// +// Generated from API version 2024-03-03 +// - resourceGroupName - The name of the resource group. +// - galleryName - The name of the Shared Image Gallery in which the inVMAccessControlProfile resides. +// - inVMAccessControlProfileName - The name of the gallery inVMAccessControlProfile in which the inVMAccessControlProfile version +// resides. +// - inVMAccessControlProfileVersionName - The name of the gallery inVMAccessControlProfile version to be deleted. +// - options - GalleryInVMAccessControlProfileVersionsClientBeginDeleteOptions contains the optional parameters for the GalleryInVMAccessControlProfileVersionsClient.BeginDelete +// method. +func (client *GalleryInVMAccessControlProfileVersionsClient) BeginDelete(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, inVMAccessControlProfileVersionName string, options *GalleryInVMAccessControlProfileVersionsClientBeginDeleteOptions) (*runtime.Poller[GalleryInVMAccessControlProfileVersionsClientDeleteResponse], error) { + if options == nil || options.ResumeToken == "" { + resp, err := client.deleteOperation(ctx, resourceGroupName, galleryName, inVMAccessControlProfileName, inVMAccessControlProfileVersionName, options) + if err != nil { + return nil, err + } + poller, err := runtime.NewPoller(resp, client.internal.Pipeline(), &runtime.NewPollerOptions[GalleryInVMAccessControlProfileVersionsClientDeleteResponse]{ + Tracer: client.internal.Tracer(), + }) + return poller, err + } else { + return runtime.NewPollerFromResumeToken(options.ResumeToken, client.internal.Pipeline(), &runtime.NewPollerFromResumeTokenOptions[GalleryInVMAccessControlProfileVersionsClientDeleteResponse]{ + Tracer: client.internal.Tracer(), + }) + } +} + +// Delete - Delete a gallery inVMAccessControlProfile version. +// If the operation fails it returns an *azcore.ResponseError type. +// +// Generated from API version 2024-03-03 +func (client *GalleryInVMAccessControlProfileVersionsClient) deleteOperation(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, inVMAccessControlProfileVersionName string, options *GalleryInVMAccessControlProfileVersionsClientBeginDeleteOptions) (*http.Response, error) { + var err error + const operationName = "GalleryInVMAccessControlProfileVersionsClient.BeginDelete" + ctx = context.WithValue(ctx, runtime.CtxAPINameKey{}, operationName) + ctx, endSpan := runtime.StartSpan(ctx, operationName, client.internal.Tracer(), nil) + defer func() { endSpan(err) }() + req, err := client.deleteCreateRequest(ctx, resourceGroupName, galleryName, inVMAccessControlProfileName, inVMAccessControlProfileVersionName, options) + if err != nil { + return nil, err + } + httpResp, err := client.internal.Pipeline().Do(req) + if err != nil { + return nil, err + } + if !runtime.HasStatusCode(httpResp, http.StatusAccepted, http.StatusNoContent) { + err = runtime.NewResponseError(httpResp) + return nil, err + } + return httpResp, nil +} + +// deleteCreateRequest creates the Delete request. +func (client *GalleryInVMAccessControlProfileVersionsClient) deleteCreateRequest(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, inVMAccessControlProfileVersionName string, options *GalleryInVMAccessControlProfileVersionsClientBeginDeleteOptions) (*policy.Request, error) { + urlPath := "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/galleries/{galleryName}/inVMAccessControlProfiles/{inVMAccessControlProfileName}/versions/{inVMAccessControlProfileVersionName}" + if client.subscriptionID == "" { + return nil, errors.New("parameter client.subscriptionID cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{subscriptionId}", url.PathEscape(client.subscriptionID)) + if resourceGroupName == "" { + return nil, errors.New("parameter resourceGroupName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{resourceGroupName}", url.PathEscape(resourceGroupName)) + if galleryName == "" { + return nil, errors.New("parameter galleryName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{galleryName}", url.PathEscape(galleryName)) + if inVMAccessControlProfileName == "" { + return nil, errors.New("parameter inVMAccessControlProfileName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{inVMAccessControlProfileName}", url.PathEscape(inVMAccessControlProfileName)) + if inVMAccessControlProfileVersionName == "" { + return nil, errors.New("parameter inVMAccessControlProfileVersionName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{inVMAccessControlProfileVersionName}", url.PathEscape(inVMAccessControlProfileVersionName)) + req, err := runtime.NewRequest(ctx, http.MethodDelete, runtime.JoinPaths(client.internal.Endpoint(), urlPath)) + if err != nil { + return nil, err + } + reqQP := req.Raw().URL.Query() + reqQP.Set("api-version", "2024-03-03") + req.Raw().URL.RawQuery = reqQP.Encode() + req.Raw().Header["Accept"] = []string{"application/json"} + return req, nil +} + +// Get - Retrieves information about a gallery inVMAccessControlProfile version. +// If the operation fails it returns an *azcore.ResponseError type. +// +// Generated from API version 2024-03-03 +// - resourceGroupName - The name of the resource group. +// - galleryName - The name of the Shared Image Gallery in which the inVMAccessControlProfile resides. +// - inVMAccessControlProfileName - The name of the gallery inVMAccessControlProfile in which the inVMAccessControlProfile version +// resides. +// - inVMAccessControlProfileVersionName - The name of the gallery inVMAccessControlProfile version to be retrieved. +// - options - GalleryInVMAccessControlProfileVersionsClientGetOptions contains the optional parameters for the GalleryInVMAccessControlProfileVersionsClient.Get +// method. +func (client *GalleryInVMAccessControlProfileVersionsClient) Get(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, inVMAccessControlProfileVersionName string, options *GalleryInVMAccessControlProfileVersionsClientGetOptions) (GalleryInVMAccessControlProfileVersionsClientGetResponse, error) { + var err error + const operationName = "GalleryInVMAccessControlProfileVersionsClient.Get" + ctx = context.WithValue(ctx, runtime.CtxAPINameKey{}, operationName) + ctx, endSpan := runtime.StartSpan(ctx, operationName, client.internal.Tracer(), nil) + defer func() { endSpan(err) }() + req, err := client.getCreateRequest(ctx, resourceGroupName, galleryName, inVMAccessControlProfileName, inVMAccessControlProfileVersionName, options) + if err != nil { + return GalleryInVMAccessControlProfileVersionsClientGetResponse{}, err + } + httpResp, err := client.internal.Pipeline().Do(req) + if err != nil { + return GalleryInVMAccessControlProfileVersionsClientGetResponse{}, err + } + if !runtime.HasStatusCode(httpResp, http.StatusOK) { + err = runtime.NewResponseError(httpResp) + return GalleryInVMAccessControlProfileVersionsClientGetResponse{}, err + } + resp, err := client.getHandleResponse(httpResp) + return resp, err +} + +// getCreateRequest creates the Get request. +func (client *GalleryInVMAccessControlProfileVersionsClient) getCreateRequest(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, inVMAccessControlProfileVersionName string, options *GalleryInVMAccessControlProfileVersionsClientGetOptions) (*policy.Request, error) { + urlPath := "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/galleries/{galleryName}/inVMAccessControlProfiles/{inVMAccessControlProfileName}/versions/{inVMAccessControlProfileVersionName}" + if client.subscriptionID == "" { + return nil, errors.New("parameter client.subscriptionID cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{subscriptionId}", url.PathEscape(client.subscriptionID)) + if resourceGroupName == "" { + return nil, errors.New("parameter resourceGroupName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{resourceGroupName}", url.PathEscape(resourceGroupName)) + if galleryName == "" { + return nil, errors.New("parameter galleryName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{galleryName}", url.PathEscape(galleryName)) + if inVMAccessControlProfileName == "" { + return nil, errors.New("parameter inVMAccessControlProfileName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{inVMAccessControlProfileName}", url.PathEscape(inVMAccessControlProfileName)) + if inVMAccessControlProfileVersionName == "" { + return nil, errors.New("parameter inVMAccessControlProfileVersionName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{inVMAccessControlProfileVersionName}", url.PathEscape(inVMAccessControlProfileVersionName)) + req, err := runtime.NewRequest(ctx, http.MethodGet, runtime.JoinPaths(client.internal.Endpoint(), urlPath)) + if err != nil { + return nil, err + } + reqQP := req.Raw().URL.Query() + reqQP.Set("api-version", "2024-03-03") + req.Raw().URL.RawQuery = reqQP.Encode() + req.Raw().Header["Accept"] = []string{"application/json"} + return req, nil +} + +// getHandleResponse handles the Get response. +func (client *GalleryInVMAccessControlProfileVersionsClient) getHandleResponse(resp *http.Response) (GalleryInVMAccessControlProfileVersionsClientGetResponse, error) { + result := GalleryInVMAccessControlProfileVersionsClientGetResponse{} + if err := runtime.UnmarshalAsJSON(resp, &result.GalleryInVMAccessControlProfileVersion); err != nil { + return GalleryInVMAccessControlProfileVersionsClientGetResponse{}, err + } + return result, nil +} + +// NewListByGalleryInVMAccessControlProfilePager - List gallery inVMAccessControlProfile versions in a gallery inVMAccessControlProfile +// +// Generated from API version 2024-03-03 +// - resourceGroupName - The name of the resource group. +// - galleryName - The name of the Shared Image Gallery in which the inVMAccessControlProfile resides. +// - inVMAccessControlProfileName - The name of the gallery inVMAccessControlProfile from which the inVMAccessControlProfile +// versions are to be listed. +// - options - GalleryInVMAccessControlProfileVersionsClientListByGalleryInVMAccessControlProfileOptions contains the optional +// parameters for the GalleryInVMAccessControlProfileVersionsClient.NewListByGalleryInVMAccessControlProfilePager method. +func (client *GalleryInVMAccessControlProfileVersionsClient) NewListByGalleryInVMAccessControlProfilePager(resourceGroupName string, galleryName string, inVMAccessControlProfileName string, options *GalleryInVMAccessControlProfileVersionsClientListByGalleryInVMAccessControlProfileOptions) *runtime.Pager[GalleryInVMAccessControlProfileVersionsClientListByGalleryInVMAccessControlProfileResponse] { + return runtime.NewPager(runtime.PagingHandler[GalleryInVMAccessControlProfileVersionsClientListByGalleryInVMAccessControlProfileResponse]{ + More: func(page GalleryInVMAccessControlProfileVersionsClientListByGalleryInVMAccessControlProfileResponse) bool { + return page.NextLink != nil && len(*page.NextLink) > 0 + }, + Fetcher: func(ctx context.Context, page *GalleryInVMAccessControlProfileVersionsClientListByGalleryInVMAccessControlProfileResponse) (GalleryInVMAccessControlProfileVersionsClientListByGalleryInVMAccessControlProfileResponse, error) { + ctx = context.WithValue(ctx, runtime.CtxAPINameKey{}, "GalleryInVMAccessControlProfileVersionsClient.NewListByGalleryInVMAccessControlProfilePager") + nextLink := "" + if page != nil { + nextLink = *page.NextLink + } + resp, err := runtime.FetcherForNextLink(ctx, client.internal.Pipeline(), nextLink, func(ctx context.Context) (*policy.Request, error) { + return client.listByGalleryInVMAccessControlProfileCreateRequest(ctx, resourceGroupName, galleryName, inVMAccessControlProfileName, options) + }, nil) + if err != nil { + return GalleryInVMAccessControlProfileVersionsClientListByGalleryInVMAccessControlProfileResponse{}, err + } + return client.listByGalleryInVMAccessControlProfileHandleResponse(resp) + }, + Tracer: client.internal.Tracer(), + }) +} + +// listByGalleryInVMAccessControlProfileCreateRequest creates the ListByGalleryInVMAccessControlProfile request. +func (client *GalleryInVMAccessControlProfileVersionsClient) listByGalleryInVMAccessControlProfileCreateRequest(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, options *GalleryInVMAccessControlProfileVersionsClientListByGalleryInVMAccessControlProfileOptions) (*policy.Request, error) { + urlPath := "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/galleries/{galleryName}/inVMAccessControlProfiles/{inVMAccessControlProfileName}/versions" + if client.subscriptionID == "" { + return nil, errors.New("parameter client.subscriptionID cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{subscriptionId}", url.PathEscape(client.subscriptionID)) + if resourceGroupName == "" { + return nil, errors.New("parameter resourceGroupName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{resourceGroupName}", url.PathEscape(resourceGroupName)) + if galleryName == "" { + return nil, errors.New("parameter galleryName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{galleryName}", url.PathEscape(galleryName)) + if inVMAccessControlProfileName == "" { + return nil, errors.New("parameter inVMAccessControlProfileName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{inVMAccessControlProfileName}", url.PathEscape(inVMAccessControlProfileName)) + req, err := runtime.NewRequest(ctx, http.MethodGet, runtime.JoinPaths(client.internal.Endpoint(), urlPath)) + if err != nil { + return nil, err + } + reqQP := req.Raw().URL.Query() + reqQP.Set("api-version", "2024-03-03") + req.Raw().URL.RawQuery = reqQP.Encode() + req.Raw().Header["Accept"] = []string{"application/json"} + return req, nil +} + +// listByGalleryInVMAccessControlProfileHandleResponse handles the ListByGalleryInVMAccessControlProfile response. +func (client *GalleryInVMAccessControlProfileVersionsClient) listByGalleryInVMAccessControlProfileHandleResponse(resp *http.Response) (GalleryInVMAccessControlProfileVersionsClientListByGalleryInVMAccessControlProfileResponse, error) { + result := GalleryInVMAccessControlProfileVersionsClientListByGalleryInVMAccessControlProfileResponse{} + if err := runtime.UnmarshalAsJSON(resp, &result.GalleryInVMAccessControlProfileVersionList); err != nil { + return GalleryInVMAccessControlProfileVersionsClientListByGalleryInVMAccessControlProfileResponse{}, err + } + return result, nil +} + +// BeginUpdate - Update a gallery inVMAccessControlProfile version. +// If the operation fails it returns an *azcore.ResponseError type. +// +// Generated from API version 2024-03-03 +// - resourceGroupName - The name of the resource group. +// - galleryName - The name of the Shared Image Gallery in which the inVMAccessControlProfile resides. +// - inVMAccessControlProfileName - The name of the gallery inVMAccessControlProfile in which the inVMAccessControlProfile version +// is to be updated. +// - inVMAccessControlProfileVersionName - The name of the gallery inVMAccessControlProfile version to be updated. Needs to +// follow semantic version name pattern: The allowed characters are digit and period. Digits must be within the range of a +// 32-bit integer. Format: .. +// - galleryInVMAccessControlProfileVersion - Parameters supplied to the update gallery inVMAccessControlProfile version operation. +// - options - GalleryInVMAccessControlProfileVersionsClientBeginUpdateOptions contains the optional parameters for the GalleryInVMAccessControlProfileVersionsClient.BeginUpdate +// method. +func (client *GalleryInVMAccessControlProfileVersionsClient) BeginUpdate(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, inVMAccessControlProfileVersionName string, galleryInVMAccessControlProfileVersion GalleryInVMAccessControlProfileVersionUpdate, options *GalleryInVMAccessControlProfileVersionsClientBeginUpdateOptions) (*runtime.Poller[GalleryInVMAccessControlProfileVersionsClientUpdateResponse], error) { + if options == nil || options.ResumeToken == "" { + resp, err := client.update(ctx, resourceGroupName, galleryName, inVMAccessControlProfileName, inVMAccessControlProfileVersionName, galleryInVMAccessControlProfileVersion, options) + if err != nil { + return nil, err + } + poller, err := runtime.NewPoller(resp, client.internal.Pipeline(), &runtime.NewPollerOptions[GalleryInVMAccessControlProfileVersionsClientUpdateResponse]{ + Tracer: client.internal.Tracer(), + }) + return poller, err + } else { + return runtime.NewPollerFromResumeToken(options.ResumeToken, client.internal.Pipeline(), &runtime.NewPollerFromResumeTokenOptions[GalleryInVMAccessControlProfileVersionsClientUpdateResponse]{ + Tracer: client.internal.Tracer(), + }) + } +} + +// Update - Update a gallery inVMAccessControlProfile version. +// If the operation fails it returns an *azcore.ResponseError type. +// +// Generated from API version 2024-03-03 +func (client *GalleryInVMAccessControlProfileVersionsClient) update(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, inVMAccessControlProfileVersionName string, galleryInVMAccessControlProfileVersion GalleryInVMAccessControlProfileVersionUpdate, options *GalleryInVMAccessControlProfileVersionsClientBeginUpdateOptions) (*http.Response, error) { + var err error + const operationName = "GalleryInVMAccessControlProfileVersionsClient.BeginUpdate" + ctx = context.WithValue(ctx, runtime.CtxAPINameKey{}, operationName) + ctx, endSpan := runtime.StartSpan(ctx, operationName, client.internal.Tracer(), nil) + defer func() { endSpan(err) }() + req, err := client.updateCreateRequest(ctx, resourceGroupName, galleryName, inVMAccessControlProfileName, inVMAccessControlProfileVersionName, galleryInVMAccessControlProfileVersion, options) + if err != nil { + return nil, err + } + httpResp, err := client.internal.Pipeline().Do(req) + if err != nil { + return nil, err + } + if !runtime.HasStatusCode(httpResp, http.StatusOK) { + err = runtime.NewResponseError(httpResp) + return nil, err + } + return httpResp, nil +} + +// updateCreateRequest creates the Update request. +func (client *GalleryInVMAccessControlProfileVersionsClient) updateCreateRequest(ctx context.Context, resourceGroupName string, galleryName string, inVMAccessControlProfileName string, inVMAccessControlProfileVersionName string, galleryInVMAccessControlProfileVersion GalleryInVMAccessControlProfileVersionUpdate, options *GalleryInVMAccessControlProfileVersionsClientBeginUpdateOptions) (*policy.Request, error) { + urlPath := "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/galleries/{galleryName}/inVMAccessControlProfiles/{inVMAccessControlProfileName}/versions/{inVMAccessControlProfileVersionName}" + if client.subscriptionID == "" { + return nil, errors.New("parameter client.subscriptionID cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{subscriptionId}", url.PathEscape(client.subscriptionID)) + if resourceGroupName == "" { + return nil, errors.New("parameter resourceGroupName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{resourceGroupName}", url.PathEscape(resourceGroupName)) + if galleryName == "" { + return nil, errors.New("parameter galleryName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{galleryName}", url.PathEscape(galleryName)) + if inVMAccessControlProfileName == "" { + return nil, errors.New("parameter inVMAccessControlProfileName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{inVMAccessControlProfileName}", url.PathEscape(inVMAccessControlProfileName)) + if inVMAccessControlProfileVersionName == "" { + return nil, errors.New("parameter inVMAccessControlProfileVersionName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{inVMAccessControlProfileVersionName}", url.PathEscape(inVMAccessControlProfileVersionName)) + req, err := runtime.NewRequest(ctx, http.MethodPatch, runtime.JoinPaths(client.internal.Endpoint(), urlPath)) + if err != nil { + return nil, err + } + reqQP := req.Raw().URL.Query() + reqQP.Set("api-version", "2024-03-03") + req.Raw().URL.RawQuery = reqQP.Encode() + req.Raw().Header["Accept"] = []string{"application/json"} + if err := runtime.MarshalAsJSON(req, galleryInVMAccessControlProfileVersion); err != nil { + return nil, err + } + return req, nil +} diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/gallerysharingprofile_client.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/gallerysharingprofile_client.go index 0ccc5ce9fd..8b0925b1dd 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/gallerysharingprofile_client.go +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/gallerysharingprofile_client.go @@ -47,7 +47,7 @@ func NewGallerySharingProfileClient(subscriptionID string, credential azcore.Tok // BeginUpdate - Update sharing profile of a gallery. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - resourceGroupName - The name of the resource group. // - galleryName - The name of the Shared Image Gallery. // - sharingUpdate - Parameters supplied to the update gallery sharing profile. @@ -73,7 +73,7 @@ func (client *GallerySharingProfileClient) BeginUpdate(ctx context.Context, reso // Update - Update sharing profile of a gallery. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 func (client *GallerySharingProfileClient) update(ctx context.Context, resourceGroupName string, galleryName string, sharingUpdate SharingUpdate, options *GallerySharingProfileClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "GallerySharingProfileClient.BeginUpdate" @@ -115,7 +115,7 @@ func (client *GallerySharingProfileClient) updateCreateRequest(ctx context.Conte return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, sharingUpdate); err != nil { diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/models.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/models.go index 95d49bff39..76d33b9bbe 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/models.go +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/models.go @@ -46,6 +46,69 @@ type APIErrorBase struct { Target *string } +// AccessControlRules - This is the Access Control Rules specification for an inVMAccessControlProfile version. +type AccessControlRules struct { + // A list of identities. + Identities []*AccessControlRulesIdentity + + // A list of privileges. + Privileges []*AccessControlRulesPrivilege + + // A list of role assignments. + RoleAssignments []*AccessControlRulesRoleAssignment + + // A list of roles. + Roles []*AccessControlRulesRole +} + +// AccessControlRulesIdentity - The properties of an Access Control Rule Identity. +type AccessControlRulesIdentity struct { + // REQUIRED; The name of the identity. + Name *string + + // The path to the executable. + ExePath *string + + // The groupName corresponding to this identity. + GroupName *string + + // The process name of the executable. + ProcessName *string + + // The username corresponding to this identity. + UserName *string +} + +// AccessControlRulesPrivilege - The properties of an Access Control Rule Privilege. +type AccessControlRulesPrivilege struct { + // REQUIRED; The name of the privilege. + Name *string + + // REQUIRED; The HTTP path corresponding to the privilege. + Path *string + + // The query parameters to match in the path. + QueryParameters map[string]*string +} + +// AccessControlRulesRole - The properties of an Access Control Rule Role. +type AccessControlRulesRole struct { + // REQUIRED; The name of the role. + Name *string + + // REQUIRED; A list of privileges needed by this role. + Privileges []*string +} + +// AccessControlRulesRoleAssignment - The properties of an Access Control Rule RoleAssignment. +type AccessControlRulesRoleAssignment struct { + // REQUIRED; A list of identities that can access the privileges defined by the role. + Identities []*string + + // REQUIRED; The name of the role. + Role *string +} + // AccessURI - A disk access SAS uri. type AccessURI struct { // READ-ONLY; A SAS uri for accessing a disk. @@ -66,6 +129,15 @@ type AdditionalCapabilities struct { UltraSSDEnabled *bool } +// AdditionalReplicaSet - Describes the additional replica set information. +type AdditionalReplicaSet struct { + // The number of direct drive replicas of the Image Version to be created.This Property is updatable + RegionalReplicaCount *int32 + + // Specifies the storage account type to be used to create the direct drive replicas + StorageAccountType *StorageAccountType +} + // AdditionalUnattendContent - Specifies additional XML formatted information that can be included in the Unattend.xml file, // which is used by Windows Setup. Contents are defined by setting name, component name, and the pass in // which the content is applied. @@ -870,7 +942,7 @@ type CommunityGalleryImageProperties struct { // managed image. Possible values are: Windows, Linux. OSType *OperatingSystemTypes - // The architecture of the image. Applicable to OS disks only. + // CPU architecture supported by an OS disk. Architecture *Architecture // The artifact tags of a community gallery resource. @@ -1095,9 +1167,8 @@ type DataDisk struct { // applicable only for managed data disks. If a previous detachment attempt of the data disk did not complete due to an unexpected // failure from the virtual machine and the disk is still not released then // use force-detach as a last resort option to detach the disk forcibly from the VM. All writes might not have been flushed - // when using this detach behavior. This feature is still in preview mode and is - // not supported for VirtualMachineScaleSet. To force-detach a data disk update toBeDetached to 'true' along with setting - // detachOption: 'ForceDetach'. + // when using this detach behavior. To force-detach a data disk update + // toBeDetached to 'true' along with setting detachOption: 'ForceDetach'. DetachOption *DiskDetachOptionTypes // Specifies the size of an empty data disk in gigabytes. This element can be used to overwrite the size of the disk in a @@ -2110,6 +2181,21 @@ type EventGridAndResourceGraph struct { Enable *bool } +// ExecutedValidation - This is the executed Validation. +type ExecutedValidation struct { + // This property specifies the starting timestamp. + ExecutionTime *time.Time + + // This property specifies the status of the validationProfile of the image version. + Status *ValidationStatus + + // This property specifies the type of image version validation. + Type *string + + // This property specifies the valid version of the validation. + Version *string +} + // ExtendedLocation - The complex type of the extended location. type ExtendedLocation struct { // The name of the extended location. @@ -2133,6 +2219,9 @@ type Gallery struct { // REQUIRED; Resource location Location *string + // The identity of the gallery, if configured. + Identity *GalleryIdentity + // Describes the properties of a Shared Image Gallery. Properties *GalleryProperties @@ -2489,6 +2578,25 @@ type GalleryIdentifier struct { UniqueName *string } +// GalleryIdentity - Identity for the virtual machine. +type GalleryIdentity struct { + // The type of identity used for the gallery. The type 'SystemAssigned, UserAssigned' includes both an implicitly created + // identity and a set of user assigned identities. The type 'None' will remove all + // identities from the gallery. + Type *ResourceIdentityType + + // The list of user identities associated with the gallery. The user identity dictionary key references will be ARM resource + // ids in the form: + // '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'. + UserAssignedIdentities map[string]*UserAssignedIdentitiesValue + + // READ-ONLY; The principal id of the gallery identity. This property will only be provided for a system assigned identity. + PrincipalID *string + + // READ-ONLY; The AAD tenant id of the gallery identity. This property will only be provided for a system assigned identity. + TenantID *string +} + // GalleryImage - Specifies information about the gallery image definition that you want to create or update. type GalleryImage struct { // REQUIRED; Resource location @@ -2515,6 +2623,9 @@ type GalleryImageFeature struct { // The name of the gallery image feature. Name *string + // The minimum gallery image version which supports this feature. + StartsAtVersion *string + // The value of the gallery image feature. Value *string } @@ -2554,7 +2665,10 @@ type GalleryImageProperties struct { // managed image. Possible values are: Windows, Linux. OSType *OperatingSystemTypes - // The architecture of the image. Applicable to OS disks only. + // Optional. Must be set to true if the gallery image features are being updated. + AllowUpdateImage *bool + + // CPU architecture supported by an OS disk. Architecture *Architecture // The description of this gallery image definition resource. This property is updatable. @@ -2649,6 +2763,9 @@ type GalleryImageVersionProperties struct { // The publishing profile of a gallery image Version. PublishingProfile *GalleryImageVersionPublishingProfile + // Indicates if this is a soft-delete resource restoration request. + Restore *bool + // This is the safety profile of the Gallery Image Version. SafetyProfile *GalleryImageVersionSafetyProfile @@ -2660,6 +2777,9 @@ type GalleryImageVersionProperties struct { // READ-ONLY; This is the replication status of the gallery image version. ReplicationStatus *ReplicationStatus + + // READ-ONLY; This is the validations profile of a Gallery Image Version. + ValidationsProfile *ValidationsProfile } // GalleryImageVersionPublishingProfile - The publishing profile of a gallery image Version. @@ -2696,6 +2816,9 @@ type GalleryImageVersionSafetyProfile struct { // Indicates whether or not removing this Gallery Image Version from replicated regions is allowed. AllowDeletionOfReplicatedLocations *bool + // Indicates whether or not the deletion is blocked for this Gallery Image Version if its End Of Life has not expired. + BlockDeletionBeforeEndOfLife *bool + // READ-ONLY; A list of Policy Violations that have been reported for this Gallery Image Version. PolicyViolations []*PolicyViolation @@ -2742,6 +2865,154 @@ type GalleryImageVersionUpdate struct { Type *string } +// GalleryInVMAccessControlProfile - Specifies information about the gallery inVMAccessControlProfile that you want to create +// or update. +type GalleryInVMAccessControlProfile struct { + // REQUIRED; Resource location + Location *string + + // Describes the properties of a gallery inVMAccessControlProfile. + Properties *GalleryInVMAccessControlProfileProperties + + // Resource tags + Tags map[string]*string + + // READ-ONLY; Resource Id + ID *string + + // READ-ONLY; Resource name + Name *string + + // READ-ONLY; Resource type + Type *string +} + +// GalleryInVMAccessControlProfileList - The List Gallery InVMAccessControlProfiles operation response. +type GalleryInVMAccessControlProfileList struct { + // REQUIRED; A list of Gallery InVMAccessControlProfiles. + Value []*GalleryInVMAccessControlProfile + + // The uri to fetch the next page of inVMAccessControlProfiles in the gallery. Call ListNext() with this to fetch the next + // page of gallery inVMAccessControlProfiles. + NextLink *string +} + +// GalleryInVMAccessControlProfileProperties - Describes the properties of a gallery inVMAccessControlProfile. +type GalleryInVMAccessControlProfileProperties struct { + // REQUIRED; This property allows you to specify the Endpoint type for which this profile is defining the access control for. + // Possible values are: 'WireServer' or 'IMDS' + ApplicableHostEndpoint *EndpointTypes + + // REQUIRED; This property allows you to specify the OS type of the VMs/VMSS for which this profile can be used against. Possible + // values are: 'Windows' or 'Linux' + OSType *OperatingSystemTypes + + // The description of this gallery inVMAccessControlProfile resources. This property is updatable. + Description *string + + // READ-ONLY; The provisioning state, which only appears in the response. + ProvisioningState *GalleryProvisioningState +} + +// GalleryInVMAccessControlProfileUpdate - Specifies information about the gallery inVMAccessControlProfile that you want +// to update. +type GalleryInVMAccessControlProfileUpdate struct { + // Describes the properties of a gallery inVMAccessControlProfile. + Properties *GalleryInVMAccessControlProfileProperties + + // Resource tags + Tags map[string]*string + + // READ-ONLY; Resource Id + ID *string + + // READ-ONLY; Resource name + Name *string + + // READ-ONLY; Resource type + Type *string +} + +// GalleryInVMAccessControlProfileVersion - Specifies information about the gallery inVMAccessControlProfile version that +// you want to create or update. +type GalleryInVMAccessControlProfileVersion struct { + // REQUIRED; Resource location + Location *string + + // Describes the properties of an inVMAccessControlProfile version. + Properties *GalleryInVMAccessControlProfileVersionProperties + + // Resource tags + Tags map[string]*string + + // READ-ONLY; Resource Id + ID *string + + // READ-ONLY; Resource name + Name *string + + // READ-ONLY; Resource type + Type *string +} + +// GalleryInVMAccessControlProfileVersionList - The List Gallery InVMAccessControlProfile Versions operation response. +type GalleryInVMAccessControlProfileVersionList struct { + // REQUIRED; A list of Gallery InVMAccessControlProfile Versions. + Value []*GalleryInVMAccessControlProfileVersion + + // The uri to fetch the next page of inVMAccessControlProfile versions. Call ListNext() with this to fetch the next page of + // gallery inVMAccessControlProfile versions. + NextLink *string +} + +// GalleryInVMAccessControlProfileVersionProperties - Describes the properties of an inVMAccessControlProfile version. +type GalleryInVMAccessControlProfileVersionProperties struct { + // REQUIRED; This property allows you to specify if the requests will be allowed to access the host endpoints. Possible values + // are: 'Allow', 'Deny'. + DefaultAccess *EndpointAccess + + // REQUIRED; This property allows you to specify whether the access control rules are in Audit mode, in Enforce mode or Disabled. + // Possible values are: 'Audit', 'Enforce' or 'Disabled'. + Mode *AccessControlRulesMode + + // If set to true, Virtual Machines deployed from the latest version of the Resource Profile won't use this Profile version. + ExcludeFromLatest *bool + + // This is the Access Control Rules specification for an inVMAccessControlProfile version. + Rules *AccessControlRules + + // The target regions where the Resource Profile version is going to be replicated to. This property is updatable. + TargetLocations []*TargetRegion + + // READ-ONLY; The provisioning state, which only appears in the response. + ProvisioningState *GalleryProvisioningState + + // READ-ONLY; The timestamp for when the Resource Profile Version is published. + PublishedDate *time.Time + + // READ-ONLY; This is the replication status of the gallery image version. + ReplicationStatus *ReplicationStatus +} + +// GalleryInVMAccessControlProfileVersionUpdate - Specifies information about the gallery inVMAccessControlProfile version +// that you want to update. +type GalleryInVMAccessControlProfileVersionUpdate struct { + // Describes the properties of an inVMAccessControlProfile version. + Properties *GalleryInVMAccessControlProfileVersionProperties + + // Resource tags + Tags map[string]*string + + // READ-ONLY; Resource Id + ID *string + + // READ-ONLY; Resource name + Name *string + + // READ-ONLY; Resource type + Type *string +} + // GalleryList - The List Galleries operation response. type GalleryList struct { // REQUIRED; A list of galleries. @@ -2749,6 +3020,9 @@ type GalleryList struct { // The uri to fetch the next page of galleries. Call ListNext() with this to fetch the next page of galleries. NextLink *string + + // The security profile of a gallery image version + SecurityProfile *ImageVersionSecurityProfile } // GalleryOSDiskImage - This is the OS disk image. @@ -2784,6 +3058,73 @@ type GalleryProperties struct { SharingStatus *SharingStatus } +// GalleryResourceProfilePropertiesBase - The properties of a gallery ResourceProfile. +type GalleryResourceProfilePropertiesBase struct { + // READ-ONLY; The provisioning state, which only appears in the response. + ProvisioningState *GalleryProvisioningState +} + +// GalleryResourceProfileVersionPropertiesBase - The properties of a gallery ResourceProfile version. +type GalleryResourceProfileVersionPropertiesBase struct { + // If set to true, Virtual Machines deployed from the latest version of the Resource Profile won't use this Profile version. + ExcludeFromLatest *bool + + // The target regions where the Resource Profile version is going to be replicated to. This property is updatable. + TargetLocations []*TargetRegion + + // READ-ONLY; The provisioning state, which only appears in the response. + ProvisioningState *GalleryProvisioningState + + // READ-ONLY; The timestamp for when the Resource Profile Version is published. + PublishedDate *time.Time + + // READ-ONLY; This is the replication status of the gallery image version. + ReplicationStatus *ReplicationStatus +} + +// GallerySoftDeletedResource - The details information of soft-deleted resource. +type GallerySoftDeletedResource struct { + // REQUIRED; Resource location + Location *string + + // Describes the properties of a soft-deleted resource. + Properties *GallerySoftDeletedResourceProperties + + // Resource tags + Tags map[string]*string + + // READ-ONLY; Resource Id + ID *string + + // READ-ONLY; Resource name + Name *string + + // READ-ONLY; Resource type + Type *string +} + +// GallerySoftDeletedResourceList - The List Soft-deleted Resources operation response. +type GallerySoftDeletedResourceList struct { + // REQUIRED; A list of soft-deleted resources. + Value []*GallerySoftDeletedResource + + // The uri to fetch the next page of soft-deleted resources. Call ListNext() with this to fetch the next page of soft-deleted + // resources. + NextLink *string +} + +// GallerySoftDeletedResourceProperties - Describes the properties of a soft-deleted resource. +type GallerySoftDeletedResourceProperties struct { + // arm id of the soft-deleted resource + ResourceArmID *string + + // artifact type of the soft-deleted resource + SoftDeletedArtifactType *SoftDeletedArtifactTypes + + // The timestamp for when the resource is soft-deleted. In dateTime offset format. + SoftDeletedTime *string +} + type GalleryTargetExtendedLocation struct { // Optional. Allows users to provide customer managed keys for encrypting the OS and data disks in the gallery artifact. Encryption *EncryptionImages @@ -2803,6 +3144,9 @@ type GalleryTargetExtendedLocation struct { // GalleryUpdate - Specifies information about the Shared Image Gallery that you want to update. type GalleryUpdate struct { + // The identity of the gallery, if configured. + Identity *GalleryIdentity + // Describes the properties of a Shared Image Gallery. Properties *GalleryProperties @@ -3925,6 +4269,15 @@ type Plan struct { Publisher *string } +// PlatformAttribute - This is the platform attribute of the image version. +type PlatformAttribute struct { + // READ-ONLY; This property specifies the name of the platformAttribute. It is read-only. + Name *string + + // READ-ONLY; This property specifies the value of the corresponding name property. It is read-only. + Value *string +} + // PolicyViolation - A policy violation reported against a gallery artifact. type PolicyViolation struct { // Describes the nature of the policy violation. @@ -5341,7 +5694,7 @@ type SharedGalleryImageProperties struct { // managed image. Possible values are: Windows, Linux. OSType *OperatingSystemTypes - // The architecture of the image. Applicable to OS disks only. + // CPU architecture supported by an OS disk. Architecture *Architecture // The artifact tags of a shared gallery resource. @@ -5773,6 +6126,9 @@ type TargetRegion struct { // REQUIRED; The name of the region. Name *string + // List of storage sku with replica count to create direct drive replicas. + AdditionalReplicaSets []*AdditionalReplicaSet + // Optional. Allows users to provide customer managed keys for encrypting the OS and data disks in the gallery artifact. Encryption *EncryptionImages @@ -6006,6 +6362,9 @@ type UserArtifactSettings struct { // Optional. The name to assign the downloaded package file on the VM. This is limited to 4096 characters. If not specified, // the package file will be named the same as the Gallery Application name. PackageFileName *string + + // Optional. The action to be taken with regards to install/update/remove of the gallery application in the event of a reboot. + ScriptBehaviorAfterReboot *GalleryApplicationScriptRebootBehavior } // UserArtifactSource - The source image from which the Image Version is going to be created. @@ -6104,6 +6463,17 @@ type VMSizeProperties struct { VCPUsPerCore *int32 } +// ValidationsProfile - This is the validations profile of a Gallery Image Version. +type ValidationsProfile struct { + ExecutedValidations []*ExecutedValidation + + // This specifies the pub, offer, sku and version of the image version metadata + PlatformAttributes []*PlatformAttribute + + // The published time of the image version + ValidationEtag *string +} + // VaultCertificate - Describes a single certificate reference in a Key Vault, and where the certificate should reside on // the VM. type VaultCertificate struct { diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/models_serde.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/models_serde.go index 46fa912263..3b44663f39 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/models_serde.go +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/models_serde.go @@ -120,6 +120,185 @@ func (a *APIErrorBase) UnmarshalJSON(data []byte) error { return nil } +// MarshalJSON implements the json.Marshaller interface for type AccessControlRules. +func (a AccessControlRules) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "identities", a.Identities) + populate(objectMap, "privileges", a.Privileges) + populate(objectMap, "roleAssignments", a.RoleAssignments) + populate(objectMap, "roles", a.Roles) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type AccessControlRules. +func (a *AccessControlRules) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", a, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "identities": + err = unpopulate(val, "Identities", &a.Identities) + delete(rawMsg, key) + case "privileges": + err = unpopulate(val, "Privileges", &a.Privileges) + delete(rawMsg, key) + case "roleAssignments": + err = unpopulate(val, "RoleAssignments", &a.RoleAssignments) + delete(rawMsg, key) + case "roles": + err = unpopulate(val, "Roles", &a.Roles) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", a, err) + } + } + return nil +} + +// MarshalJSON implements the json.Marshaller interface for type AccessControlRulesIdentity. +func (a AccessControlRulesIdentity) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "exePath", a.ExePath) + populate(objectMap, "groupName", a.GroupName) + populate(objectMap, "name", a.Name) + populate(objectMap, "processName", a.ProcessName) + populate(objectMap, "userName", a.UserName) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type AccessControlRulesIdentity. +func (a *AccessControlRulesIdentity) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", a, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "exePath": + err = unpopulate(val, "ExePath", &a.ExePath) + delete(rawMsg, key) + case "groupName": + err = unpopulate(val, "GroupName", &a.GroupName) + delete(rawMsg, key) + case "name": + err = unpopulate(val, "Name", &a.Name) + delete(rawMsg, key) + case "processName": + err = unpopulate(val, "ProcessName", &a.ProcessName) + delete(rawMsg, key) + case "userName": + err = unpopulate(val, "UserName", &a.UserName) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", a, err) + } + } + return nil +} + +// MarshalJSON implements the json.Marshaller interface for type AccessControlRulesPrivilege. +func (a AccessControlRulesPrivilege) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "name", a.Name) + populate(objectMap, "path", a.Path) + populate(objectMap, "queryParameters", a.QueryParameters) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type AccessControlRulesPrivilege. +func (a *AccessControlRulesPrivilege) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", a, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "name": + err = unpopulate(val, "Name", &a.Name) + delete(rawMsg, key) + case "path": + err = unpopulate(val, "Path", &a.Path) + delete(rawMsg, key) + case "queryParameters": + err = unpopulate(val, "QueryParameters", &a.QueryParameters) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", a, err) + } + } + return nil +} + +// MarshalJSON implements the json.Marshaller interface for type AccessControlRulesRole. +func (a AccessControlRulesRole) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "name", a.Name) + populate(objectMap, "privileges", a.Privileges) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type AccessControlRulesRole. +func (a *AccessControlRulesRole) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", a, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "name": + err = unpopulate(val, "Name", &a.Name) + delete(rawMsg, key) + case "privileges": + err = unpopulate(val, "Privileges", &a.Privileges) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", a, err) + } + } + return nil +} + +// MarshalJSON implements the json.Marshaller interface for type AccessControlRulesRoleAssignment. +func (a AccessControlRulesRoleAssignment) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "identities", a.Identities) + populate(objectMap, "role", a.Role) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type AccessControlRulesRoleAssignment. +func (a *AccessControlRulesRoleAssignment) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", a, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "identities": + err = unpopulate(val, "Identities", &a.Identities) + delete(rawMsg, key) + case "role": + err = unpopulate(val, "Role", &a.Role) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", a, err) + } + } + return nil +} + // MarshalJSON implements the json.Marshaller interface for type AccessURI. func (a AccessURI) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) @@ -182,6 +361,37 @@ func (a *AdditionalCapabilities) UnmarshalJSON(data []byte) error { return nil } +// MarshalJSON implements the json.Marshaller interface for type AdditionalReplicaSet. +func (a AdditionalReplicaSet) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "regionalReplicaCount", a.RegionalReplicaCount) + populate(objectMap, "storageAccountType", a.StorageAccountType) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type AdditionalReplicaSet. +func (a *AdditionalReplicaSet) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", a, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "regionalReplicaCount": + err = unpopulate(val, "RegionalReplicaCount", &a.RegionalReplicaCount) + delete(rawMsg, key) + case "storageAccountType": + err = unpopulate(val, "StorageAccountType", &a.StorageAccountType) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", a, err) + } + } + return nil +} + // MarshalJSON implements the json.Marshaller interface for type AdditionalUnattendContent. func (a AdditionalUnattendContent) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) @@ -4804,6 +5014,45 @@ func (e *EventGridAndResourceGraph) UnmarshalJSON(data []byte) error { return nil } +// MarshalJSON implements the json.Marshaller interface for type ExecutedValidation. +func (e ExecutedValidation) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populateDateTimeRFC3339(objectMap, "executionTime", e.ExecutionTime) + populate(objectMap, "status", e.Status) + populate(objectMap, "type", e.Type) + populate(objectMap, "version", e.Version) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type ExecutedValidation. +func (e *ExecutedValidation) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", e, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "executionTime": + err = unpopulateDateTimeRFC3339(val, "ExecutionTime", &e.ExecutionTime) + delete(rawMsg, key) + case "status": + err = unpopulate(val, "Status", &e.Status) + delete(rawMsg, key) + case "type": + err = unpopulate(val, "Type", &e.Type) + delete(rawMsg, key) + case "version": + err = unpopulate(val, "Version", &e.Version) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", e, err) + } + } + return nil +} + // MarshalJSON implements the json.Marshaller interface for type ExtendedLocation. func (e ExtendedLocation) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) @@ -4870,6 +5119,7 @@ func (e *Extension) UnmarshalJSON(data []byte) error { func (g Gallery) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) populate(objectMap, "id", g.ID) + populate(objectMap, "identity", g.Identity) populate(objectMap, "location", g.Location) populate(objectMap, "name", g.Name) populate(objectMap, "properties", g.Properties) @@ -4890,6 +5140,9 @@ func (g *Gallery) UnmarshalJSON(data []byte) error { case "id": err = unpopulate(val, "ID", &g.ID) delete(rawMsg, key) + case "identity": + err = unpopulate(val, "Identity", &g.Identity) + delete(rawMsg, key) case "location": err = unpopulate(val, "Location", &g.Location) delete(rawMsg, key) @@ -5771,6 +6024,45 @@ func (g *GalleryIdentifier) UnmarshalJSON(data []byte) error { return nil } +// MarshalJSON implements the json.Marshaller interface for type GalleryIdentity. +func (g GalleryIdentity) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "principalId", g.PrincipalID) + populate(objectMap, "tenantId", g.TenantID) + populate(objectMap, "type", g.Type) + populate(objectMap, "userAssignedIdentities", g.UserAssignedIdentities) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type GalleryIdentity. +func (g *GalleryIdentity) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "principalId": + err = unpopulate(val, "PrincipalID", &g.PrincipalID) + delete(rawMsg, key) + case "tenantId": + err = unpopulate(val, "TenantID", &g.TenantID) + delete(rawMsg, key) + case "type": + err = unpopulate(val, "Type", &g.Type) + delete(rawMsg, key) + case "userAssignedIdentities": + err = unpopulate(val, "UserAssignedIdentities", &g.UserAssignedIdentities) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + } + return nil +} + // MarshalJSON implements the json.Marshaller interface for type GalleryImage. func (g GalleryImage) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) @@ -5822,6 +6114,7 @@ func (g *GalleryImage) UnmarshalJSON(data []byte) error { func (g GalleryImageFeature) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) populate(objectMap, "name", g.Name) + populate(objectMap, "startsAtVersion", g.StartsAtVersion) populate(objectMap, "value", g.Value) return json.Marshal(objectMap) } @@ -5838,6 +6131,9 @@ func (g *GalleryImageFeature) UnmarshalJSON(data []byte) error { case "name": err = unpopulate(val, "Name", &g.Name) delete(rawMsg, key) + case "startsAtVersion": + err = unpopulate(val, "StartsAtVersion", &g.StartsAtVersion) + delete(rawMsg, key) case "value": err = unpopulate(val, "Value", &g.Value) delete(rawMsg, key) @@ -5918,6 +6214,7 @@ func (g *GalleryImageList) UnmarshalJSON(data []byte) error { // MarshalJSON implements the json.Marshaller interface for type GalleryImageProperties. func (g GalleryImageProperties) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) + populate(objectMap, "allowUpdateImage", g.AllowUpdateImage) populate(objectMap, "architecture", g.Architecture) populate(objectMap, "description", g.Description) populate(objectMap, "disallowed", g.Disallowed) @@ -5945,6 +6242,9 @@ func (g *GalleryImageProperties) UnmarshalJSON(data []byte) error { for key, val := range rawMsg { var err error switch key { + case "allowUpdateImage": + err = unpopulate(val, "AllowUpdateImage", &g.AllowUpdateImage) + delete(rawMsg, key) case "architecture": err = unpopulate(val, "Architecture", &g.Architecture) delete(rawMsg, key) @@ -6125,9 +6425,11 @@ func (g GalleryImageVersionProperties) MarshalJSON() ([]byte, error) { populate(objectMap, "provisioningState", g.ProvisioningState) populate(objectMap, "publishingProfile", g.PublishingProfile) populate(objectMap, "replicationStatus", g.ReplicationStatus) + populate(objectMap, "restore", g.Restore) populate(objectMap, "safetyProfile", g.SafetyProfile) populate(objectMap, "securityProfile", g.SecurityProfile) populate(objectMap, "storageProfile", g.StorageProfile) + populate(objectMap, "validationsProfile", g.ValidationsProfile) return json.Marshal(objectMap) } @@ -6149,6 +6451,9 @@ func (g *GalleryImageVersionProperties) UnmarshalJSON(data []byte) error { case "replicationStatus": err = unpopulate(val, "ReplicationStatus", &g.ReplicationStatus) delete(rawMsg, key) + case "restore": + err = unpopulate(val, "Restore", &g.Restore) + delete(rawMsg, key) case "safetyProfile": err = unpopulate(val, "SafetyProfile", &g.SafetyProfile) delete(rawMsg, key) @@ -6158,6 +6463,9 @@ func (g *GalleryImageVersionProperties) UnmarshalJSON(data []byte) error { case "storageProfile": err = unpopulate(val, "StorageProfile", &g.StorageProfile) delete(rawMsg, key) + case "validationsProfile": + err = unpopulate(val, "ValidationsProfile", &g.ValidationsProfile) + delete(rawMsg, key) } if err != nil { return fmt.Errorf("unmarshalling type %T: %v", g, err) @@ -6225,6 +6533,7 @@ func (g *GalleryImageVersionPublishingProfile) UnmarshalJSON(data []byte) error func (g GalleryImageVersionSafetyProfile) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) populate(objectMap, "allowDeletionOfReplicatedLocations", g.AllowDeletionOfReplicatedLocations) + populate(objectMap, "blockDeletionBeforeEndOfLife", g.BlockDeletionBeforeEndOfLife) populate(objectMap, "policyViolations", g.PolicyViolations) populate(objectMap, "reportedForPolicyViolation", g.ReportedForPolicyViolation) return json.Marshal(objectMap) @@ -6242,6 +6551,9 @@ func (g *GalleryImageVersionSafetyProfile) UnmarshalJSON(data []byte) error { case "allowDeletionOfReplicatedLocations": err = unpopulate(val, "AllowDeletionOfReplicatedLocations", &g.AllowDeletionOfReplicatedLocations) delete(rawMsg, key) + case "blockDeletionBeforeEndOfLife": + err = unpopulate(val, "BlockDeletionBeforeEndOfLife", &g.BlockDeletionBeforeEndOfLife) + delete(rawMsg, key) case "policyViolations": err = unpopulate(val, "PolicyViolations", &g.PolicyViolations) delete(rawMsg, key) @@ -6265,8 +6577,323 @@ func (g GalleryImageVersionStorageProfile) MarshalJSON() ([]byte, error) { return json.Marshal(objectMap) } -// UnmarshalJSON implements the json.Unmarshaller interface for type GalleryImageVersionStorageProfile. -func (g *GalleryImageVersionStorageProfile) UnmarshalJSON(data []byte) error { +// UnmarshalJSON implements the json.Unmarshaller interface for type GalleryImageVersionStorageProfile. +func (g *GalleryImageVersionStorageProfile) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "dataDiskImages": + err = unpopulate(val, "DataDiskImages", &g.DataDiskImages) + delete(rawMsg, key) + case "osDiskImage": + err = unpopulate(val, "OSDiskImage", &g.OSDiskImage) + delete(rawMsg, key) + case "source": + err = unpopulate(val, "Source", &g.Source) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + } + return nil +} + +// MarshalJSON implements the json.Marshaller interface for type GalleryImageVersionUefiSettings. +func (g GalleryImageVersionUefiSettings) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "additionalSignatures", g.AdditionalSignatures) + populate(objectMap, "signatureTemplateNames", g.SignatureTemplateNames) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type GalleryImageVersionUefiSettings. +func (g *GalleryImageVersionUefiSettings) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "additionalSignatures": + err = unpopulate(val, "AdditionalSignatures", &g.AdditionalSignatures) + delete(rawMsg, key) + case "signatureTemplateNames": + err = unpopulate(val, "SignatureTemplateNames", &g.SignatureTemplateNames) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + } + return nil +} + +// MarshalJSON implements the json.Marshaller interface for type GalleryImageVersionUpdate. +func (g GalleryImageVersionUpdate) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "id", g.ID) + populate(objectMap, "name", g.Name) + populate(objectMap, "properties", g.Properties) + populate(objectMap, "tags", g.Tags) + populate(objectMap, "type", g.Type) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type GalleryImageVersionUpdate. +func (g *GalleryImageVersionUpdate) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "id": + err = unpopulate(val, "ID", &g.ID) + delete(rawMsg, key) + case "name": + err = unpopulate(val, "Name", &g.Name) + delete(rawMsg, key) + case "properties": + err = unpopulate(val, "Properties", &g.Properties) + delete(rawMsg, key) + case "tags": + err = unpopulate(val, "Tags", &g.Tags) + delete(rawMsg, key) + case "type": + err = unpopulate(val, "Type", &g.Type) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + } + return nil +} + +// MarshalJSON implements the json.Marshaller interface for type GalleryInVMAccessControlProfile. +func (g GalleryInVMAccessControlProfile) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "id", g.ID) + populate(objectMap, "location", g.Location) + populate(objectMap, "name", g.Name) + populate(objectMap, "properties", g.Properties) + populate(objectMap, "tags", g.Tags) + populate(objectMap, "type", g.Type) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type GalleryInVMAccessControlProfile. +func (g *GalleryInVMAccessControlProfile) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "id": + err = unpopulate(val, "ID", &g.ID) + delete(rawMsg, key) + case "location": + err = unpopulate(val, "Location", &g.Location) + delete(rawMsg, key) + case "name": + err = unpopulate(val, "Name", &g.Name) + delete(rawMsg, key) + case "properties": + err = unpopulate(val, "Properties", &g.Properties) + delete(rawMsg, key) + case "tags": + err = unpopulate(val, "Tags", &g.Tags) + delete(rawMsg, key) + case "type": + err = unpopulate(val, "Type", &g.Type) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + } + return nil +} + +// MarshalJSON implements the json.Marshaller interface for type GalleryInVMAccessControlProfileList. +func (g GalleryInVMAccessControlProfileList) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "nextLink", g.NextLink) + populate(objectMap, "value", g.Value) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type GalleryInVMAccessControlProfileList. +func (g *GalleryInVMAccessControlProfileList) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "nextLink": + err = unpopulate(val, "NextLink", &g.NextLink) + delete(rawMsg, key) + case "value": + err = unpopulate(val, "Value", &g.Value) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + } + return nil +} + +// MarshalJSON implements the json.Marshaller interface for type GalleryInVMAccessControlProfileProperties. +func (g GalleryInVMAccessControlProfileProperties) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "applicableHostEndpoint", g.ApplicableHostEndpoint) + populate(objectMap, "description", g.Description) + populate(objectMap, "osType", g.OSType) + populate(objectMap, "provisioningState", g.ProvisioningState) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type GalleryInVMAccessControlProfileProperties. +func (g *GalleryInVMAccessControlProfileProperties) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "applicableHostEndpoint": + err = unpopulate(val, "ApplicableHostEndpoint", &g.ApplicableHostEndpoint) + delete(rawMsg, key) + case "description": + err = unpopulate(val, "Description", &g.Description) + delete(rawMsg, key) + case "osType": + err = unpopulate(val, "OSType", &g.OSType) + delete(rawMsg, key) + case "provisioningState": + err = unpopulate(val, "ProvisioningState", &g.ProvisioningState) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + } + return nil +} + +// MarshalJSON implements the json.Marshaller interface for type GalleryInVMAccessControlProfileUpdate. +func (g GalleryInVMAccessControlProfileUpdate) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "id", g.ID) + populate(objectMap, "name", g.Name) + populate(objectMap, "properties", g.Properties) + populate(objectMap, "tags", g.Tags) + populate(objectMap, "type", g.Type) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type GalleryInVMAccessControlProfileUpdate. +func (g *GalleryInVMAccessControlProfileUpdate) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "id": + err = unpopulate(val, "ID", &g.ID) + delete(rawMsg, key) + case "name": + err = unpopulate(val, "Name", &g.Name) + delete(rawMsg, key) + case "properties": + err = unpopulate(val, "Properties", &g.Properties) + delete(rawMsg, key) + case "tags": + err = unpopulate(val, "Tags", &g.Tags) + delete(rawMsg, key) + case "type": + err = unpopulate(val, "Type", &g.Type) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + } + return nil +} + +// MarshalJSON implements the json.Marshaller interface for type GalleryInVMAccessControlProfileVersion. +func (g GalleryInVMAccessControlProfileVersion) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "id", g.ID) + populate(objectMap, "location", g.Location) + populate(objectMap, "name", g.Name) + populate(objectMap, "properties", g.Properties) + populate(objectMap, "tags", g.Tags) + populate(objectMap, "type", g.Type) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type GalleryInVMAccessControlProfileVersion. +func (g *GalleryInVMAccessControlProfileVersion) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "id": + err = unpopulate(val, "ID", &g.ID) + delete(rawMsg, key) + case "location": + err = unpopulate(val, "Location", &g.Location) + delete(rawMsg, key) + case "name": + err = unpopulate(val, "Name", &g.Name) + delete(rawMsg, key) + case "properties": + err = unpopulate(val, "Properties", &g.Properties) + delete(rawMsg, key) + case "tags": + err = unpopulate(val, "Tags", &g.Tags) + delete(rawMsg, key) + case "type": + err = unpopulate(val, "Type", &g.Type) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + } + return nil +} + +// MarshalJSON implements the json.Marshaller interface for type GalleryInVMAccessControlProfileVersionList. +func (g GalleryInVMAccessControlProfileVersionList) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "nextLink", g.NextLink) + populate(objectMap, "value", g.Value) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type GalleryInVMAccessControlProfileVersionList. +func (g *GalleryInVMAccessControlProfileVersionList) UnmarshalJSON(data []byte) error { var rawMsg map[string]json.RawMessage if err := json.Unmarshal(data, &rawMsg); err != nil { return fmt.Errorf("unmarshalling type %T: %v", g, err) @@ -6274,14 +6901,11 @@ func (g *GalleryImageVersionStorageProfile) UnmarshalJSON(data []byte) error { for key, val := range rawMsg { var err error switch key { - case "dataDiskImages": - err = unpopulate(val, "DataDiskImages", &g.DataDiskImages) - delete(rawMsg, key) - case "osDiskImage": - err = unpopulate(val, "OSDiskImage", &g.OSDiskImage) + case "nextLink": + err = unpopulate(val, "NextLink", &g.NextLink) delete(rawMsg, key) - case "source": - err = unpopulate(val, "Source", &g.Source) + case "value": + err = unpopulate(val, "Value", &g.Value) delete(rawMsg, key) } if err != nil { @@ -6291,16 +6915,22 @@ func (g *GalleryImageVersionStorageProfile) UnmarshalJSON(data []byte) error { return nil } -// MarshalJSON implements the json.Marshaller interface for type GalleryImageVersionUefiSettings. -func (g GalleryImageVersionUefiSettings) MarshalJSON() ([]byte, error) { +// MarshalJSON implements the json.Marshaller interface for type GalleryInVMAccessControlProfileVersionProperties. +func (g GalleryInVMAccessControlProfileVersionProperties) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) - populate(objectMap, "additionalSignatures", g.AdditionalSignatures) - populate(objectMap, "signatureTemplateNames", g.SignatureTemplateNames) + populate(objectMap, "defaultAccess", g.DefaultAccess) + populate(objectMap, "excludeFromLatest", g.ExcludeFromLatest) + populate(objectMap, "mode", g.Mode) + populate(objectMap, "provisioningState", g.ProvisioningState) + populateDateTimeRFC3339(objectMap, "publishedDate", g.PublishedDate) + populate(objectMap, "replicationStatus", g.ReplicationStatus) + populate(objectMap, "rules", g.Rules) + populate(objectMap, "targetLocations", g.TargetLocations) return json.Marshal(objectMap) } -// UnmarshalJSON implements the json.Unmarshaller interface for type GalleryImageVersionUefiSettings. -func (g *GalleryImageVersionUefiSettings) UnmarshalJSON(data []byte) error { +// UnmarshalJSON implements the json.Unmarshaller interface for type GalleryInVMAccessControlProfileVersionProperties. +func (g *GalleryInVMAccessControlProfileVersionProperties) UnmarshalJSON(data []byte) error { var rawMsg map[string]json.RawMessage if err := json.Unmarshal(data, &rawMsg); err != nil { return fmt.Errorf("unmarshalling type %T: %v", g, err) @@ -6308,11 +6938,29 @@ func (g *GalleryImageVersionUefiSettings) UnmarshalJSON(data []byte) error { for key, val := range rawMsg { var err error switch key { - case "additionalSignatures": - err = unpopulate(val, "AdditionalSignatures", &g.AdditionalSignatures) + case "defaultAccess": + err = unpopulate(val, "DefaultAccess", &g.DefaultAccess) delete(rawMsg, key) - case "signatureTemplateNames": - err = unpopulate(val, "SignatureTemplateNames", &g.SignatureTemplateNames) + case "excludeFromLatest": + err = unpopulate(val, "ExcludeFromLatest", &g.ExcludeFromLatest) + delete(rawMsg, key) + case "mode": + err = unpopulate(val, "Mode", &g.Mode) + delete(rawMsg, key) + case "provisioningState": + err = unpopulate(val, "ProvisioningState", &g.ProvisioningState) + delete(rawMsg, key) + case "publishedDate": + err = unpopulateDateTimeRFC3339(val, "PublishedDate", &g.PublishedDate) + delete(rawMsg, key) + case "replicationStatus": + err = unpopulate(val, "ReplicationStatus", &g.ReplicationStatus) + delete(rawMsg, key) + case "rules": + err = unpopulate(val, "Rules", &g.Rules) + delete(rawMsg, key) + case "targetLocations": + err = unpopulate(val, "TargetLocations", &g.TargetLocations) delete(rawMsg, key) } if err != nil { @@ -6322,8 +6970,8 @@ func (g *GalleryImageVersionUefiSettings) UnmarshalJSON(data []byte) error { return nil } -// MarshalJSON implements the json.Marshaller interface for type GalleryImageVersionUpdate. -func (g GalleryImageVersionUpdate) MarshalJSON() ([]byte, error) { +// MarshalJSON implements the json.Marshaller interface for type GalleryInVMAccessControlProfileVersionUpdate. +func (g GalleryInVMAccessControlProfileVersionUpdate) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) populate(objectMap, "id", g.ID) populate(objectMap, "name", g.Name) @@ -6333,8 +6981,8 @@ func (g GalleryImageVersionUpdate) MarshalJSON() ([]byte, error) { return json.Marshal(objectMap) } -// UnmarshalJSON implements the json.Unmarshaller interface for type GalleryImageVersionUpdate. -func (g *GalleryImageVersionUpdate) UnmarshalJSON(data []byte) error { +// UnmarshalJSON implements the json.Unmarshaller interface for type GalleryInVMAccessControlProfileVersionUpdate. +func (g *GalleryInVMAccessControlProfileVersionUpdate) UnmarshalJSON(data []byte) error { var rawMsg map[string]json.RawMessage if err := json.Unmarshal(data, &rawMsg); err != nil { return fmt.Errorf("unmarshalling type %T: %v", g, err) @@ -6369,6 +7017,7 @@ func (g *GalleryImageVersionUpdate) UnmarshalJSON(data []byte) error { func (g GalleryList) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) populate(objectMap, "nextLink", g.NextLink) + populate(objectMap, "securityProfile", g.SecurityProfile) populate(objectMap, "value", g.Value) return json.Marshal(objectMap) } @@ -6385,6 +7034,9 @@ func (g *GalleryList) UnmarshalJSON(data []byte) error { case "nextLink": err = unpopulate(val, "NextLink", &g.NextLink) delete(rawMsg, key) + case "securityProfile": + err = unpopulate(val, "SecurityProfile", &g.SecurityProfile) + delete(rawMsg, key) case "value": err = unpopulate(val, "Value", &g.Value) delete(rawMsg, key) @@ -6478,6 +7130,189 @@ func (g *GalleryProperties) UnmarshalJSON(data []byte) error { return nil } +// MarshalJSON implements the json.Marshaller interface for type GalleryResourceProfilePropertiesBase. +func (g GalleryResourceProfilePropertiesBase) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "provisioningState", g.ProvisioningState) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type GalleryResourceProfilePropertiesBase. +func (g *GalleryResourceProfilePropertiesBase) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "provisioningState": + err = unpopulate(val, "ProvisioningState", &g.ProvisioningState) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + } + return nil +} + +// MarshalJSON implements the json.Marshaller interface for type GalleryResourceProfileVersionPropertiesBase. +func (g GalleryResourceProfileVersionPropertiesBase) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "excludeFromLatest", g.ExcludeFromLatest) + populate(objectMap, "provisioningState", g.ProvisioningState) + populateDateTimeRFC3339(objectMap, "publishedDate", g.PublishedDate) + populate(objectMap, "replicationStatus", g.ReplicationStatus) + populate(objectMap, "targetLocations", g.TargetLocations) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type GalleryResourceProfileVersionPropertiesBase. +func (g *GalleryResourceProfileVersionPropertiesBase) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "excludeFromLatest": + err = unpopulate(val, "ExcludeFromLatest", &g.ExcludeFromLatest) + delete(rawMsg, key) + case "provisioningState": + err = unpopulate(val, "ProvisioningState", &g.ProvisioningState) + delete(rawMsg, key) + case "publishedDate": + err = unpopulateDateTimeRFC3339(val, "PublishedDate", &g.PublishedDate) + delete(rawMsg, key) + case "replicationStatus": + err = unpopulate(val, "ReplicationStatus", &g.ReplicationStatus) + delete(rawMsg, key) + case "targetLocations": + err = unpopulate(val, "TargetLocations", &g.TargetLocations) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + } + return nil +} + +// MarshalJSON implements the json.Marshaller interface for type GallerySoftDeletedResource. +func (g GallerySoftDeletedResource) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "id", g.ID) + populate(objectMap, "location", g.Location) + populate(objectMap, "name", g.Name) + populate(objectMap, "properties", g.Properties) + populate(objectMap, "tags", g.Tags) + populate(objectMap, "type", g.Type) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type GallerySoftDeletedResource. +func (g *GallerySoftDeletedResource) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "id": + err = unpopulate(val, "ID", &g.ID) + delete(rawMsg, key) + case "location": + err = unpopulate(val, "Location", &g.Location) + delete(rawMsg, key) + case "name": + err = unpopulate(val, "Name", &g.Name) + delete(rawMsg, key) + case "properties": + err = unpopulate(val, "Properties", &g.Properties) + delete(rawMsg, key) + case "tags": + err = unpopulate(val, "Tags", &g.Tags) + delete(rawMsg, key) + case "type": + err = unpopulate(val, "Type", &g.Type) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + } + return nil +} + +// MarshalJSON implements the json.Marshaller interface for type GallerySoftDeletedResourceList. +func (g GallerySoftDeletedResourceList) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "nextLink", g.NextLink) + populate(objectMap, "value", g.Value) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type GallerySoftDeletedResourceList. +func (g *GallerySoftDeletedResourceList) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "nextLink": + err = unpopulate(val, "NextLink", &g.NextLink) + delete(rawMsg, key) + case "value": + err = unpopulate(val, "Value", &g.Value) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + } + return nil +} + +// MarshalJSON implements the json.Marshaller interface for type GallerySoftDeletedResourceProperties. +func (g GallerySoftDeletedResourceProperties) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "resourceArmId", g.ResourceArmID) + populate(objectMap, "softDeletedArtifactType", g.SoftDeletedArtifactType) + populate(objectMap, "softDeletedTime", g.SoftDeletedTime) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type GallerySoftDeletedResourceProperties. +func (g *GallerySoftDeletedResourceProperties) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "resourceArmId": + err = unpopulate(val, "ResourceArmID", &g.ResourceArmID) + delete(rawMsg, key) + case "softDeletedArtifactType": + err = unpopulate(val, "SoftDeletedArtifactType", &g.SoftDeletedArtifactType) + delete(rawMsg, key) + case "softDeletedTime": + err = unpopulate(val, "SoftDeletedTime", &g.SoftDeletedTime) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", g, err) + } + } + return nil +} + // MarshalJSON implements the json.Marshaller interface for type GalleryTargetExtendedLocation. func (g GalleryTargetExtendedLocation) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) @@ -6525,6 +7360,7 @@ func (g *GalleryTargetExtendedLocation) UnmarshalJSON(data []byte) error { func (g GalleryUpdate) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) populate(objectMap, "id", g.ID) + populate(objectMap, "identity", g.Identity) populate(objectMap, "name", g.Name) populate(objectMap, "properties", g.Properties) populate(objectMap, "tags", g.Tags) @@ -6544,6 +7380,9 @@ func (g *GalleryUpdate) UnmarshalJSON(data []byte) error { case "id": err = unpopulate(val, "ID", &g.ID) delete(rawMsg, key) + case "identity": + err = unpopulate(val, "Identity", &g.Identity) + delete(rawMsg, key) case "name": err = unpopulate(val, "Name", &g.Name) delete(rawMsg, key) @@ -9135,6 +9974,37 @@ func (p *Plan) UnmarshalJSON(data []byte) error { return nil } +// MarshalJSON implements the json.Marshaller interface for type PlatformAttribute. +func (p PlatformAttribute) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "name", p.Name) + populate(objectMap, "value", p.Value) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type PlatformAttribute. +func (p *PlatformAttribute) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", p, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "name": + err = unpopulate(val, "Name", &p.Name) + delete(rawMsg, key) + case "value": + err = unpopulate(val, "Value", &p.Value) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", p, err) + } + } + return nil +} + // MarshalJSON implements the json.Marshaller interface for type PolicyViolation. func (p PolicyViolation) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) @@ -13965,6 +14835,7 @@ func (s *SystemData) UnmarshalJSON(data []byte) error { // MarshalJSON implements the json.Marshaller interface for type TargetRegion. func (t TargetRegion) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) + populate(objectMap, "additionalReplicaSets", t.AdditionalReplicaSets) populate(objectMap, "encryption", t.Encryption) populate(objectMap, "excludeFromLatest", t.ExcludeFromLatest) populate(objectMap, "name", t.Name) @@ -13982,6 +14853,9 @@ func (t *TargetRegion) UnmarshalJSON(data []byte) error { for key, val := range rawMsg { var err error switch key { + case "additionalReplicaSets": + err = unpopulate(val, "AdditionalReplicaSets", &t.AdditionalReplicaSets) + delete(rawMsg, key) case "encryption": err = unpopulate(val, "Encryption", &t.Encryption) delete(rawMsg, key) @@ -14582,6 +15456,7 @@ func (u UserArtifactSettings) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) populate(objectMap, "configFileName", u.ConfigFileName) populate(objectMap, "packageFileName", u.PackageFileName) + populate(objectMap, "scriptBehaviorAfterReboot", u.ScriptBehaviorAfterReboot) return json.Marshal(objectMap) } @@ -14600,6 +15475,9 @@ func (u *UserArtifactSettings) UnmarshalJSON(data []byte) error { case "packageFileName": err = unpopulate(val, "PackageFileName", &u.PackageFileName) delete(rawMsg, key) + case "scriptBehaviorAfterReboot": + err = unpopulate(val, "ScriptBehaviorAfterReboot", &u.ScriptBehaviorAfterReboot) + delete(rawMsg, key) } if err != nil { return fmt.Errorf("unmarshalling type %T: %v", u, err) @@ -14891,6 +15769,41 @@ func (v *VMSizeProperties) UnmarshalJSON(data []byte) error { return nil } +// MarshalJSON implements the json.Marshaller interface for type ValidationsProfile. +func (v ValidationsProfile) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "executedValidations", v.ExecutedValidations) + populate(objectMap, "platformAttributes", v.PlatformAttributes) + populate(objectMap, "validationEtag", v.ValidationEtag) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type ValidationsProfile. +func (v *ValidationsProfile) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", v, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "executedValidations": + err = unpopulate(val, "ExecutedValidations", &v.ExecutedValidations) + delete(rawMsg, key) + case "platformAttributes": + err = unpopulate(val, "PlatformAttributes", &v.PlatformAttributes) + delete(rawMsg, key) + case "validationEtag": + err = unpopulate(val, "ValidationEtag", &v.ValidationEtag) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", v, err) + } + } + return nil +} + // MarshalJSON implements the json.Marshaller interface for type VaultCertificate. func (v VaultCertificate) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/options.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/options.go index c94e80f302..b1ba703ab9 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/options.go +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/options.go @@ -33,7 +33,7 @@ type AvailabilitySetsClientListAvailableSizesOptions struct { // AvailabilitySetsClientListBySubscriptionOptions contains the optional parameters for the AvailabilitySetsClient.NewListBySubscriptionPager // method. type AvailabilitySetsClientListBySubscriptionOptions struct { - // The expand expression to apply to the operation. Allowed values are 'instanceView'. + // The expand expression to apply to the operation. Allowed values are 'virtualMachines/$ref'. Expand *string } @@ -793,6 +793,72 @@ type GalleryImagesClientListByGalleryOptions struct { // placeholder for future optional parameters } +// GalleryInVMAccessControlProfileVersionsClientBeginCreateOrUpdateOptions contains the optional parameters for the GalleryInVMAccessControlProfileVersionsClient.BeginCreateOrUpdate +// method. +type GalleryInVMAccessControlProfileVersionsClientBeginCreateOrUpdateOptions struct { + // Resumes the LRO from the provided token. + ResumeToken string +} + +// GalleryInVMAccessControlProfileVersionsClientBeginDeleteOptions contains the optional parameters for the GalleryInVMAccessControlProfileVersionsClient.BeginDelete +// method. +type GalleryInVMAccessControlProfileVersionsClientBeginDeleteOptions struct { + // Resumes the LRO from the provided token. + ResumeToken string +} + +// GalleryInVMAccessControlProfileVersionsClientBeginUpdateOptions contains the optional parameters for the GalleryInVMAccessControlProfileVersionsClient.BeginUpdate +// method. +type GalleryInVMAccessControlProfileVersionsClientBeginUpdateOptions struct { + // Resumes the LRO from the provided token. + ResumeToken string +} + +// GalleryInVMAccessControlProfileVersionsClientGetOptions contains the optional parameters for the GalleryInVMAccessControlProfileVersionsClient.Get +// method. +type GalleryInVMAccessControlProfileVersionsClientGetOptions struct { + // placeholder for future optional parameters +} + +// GalleryInVMAccessControlProfileVersionsClientListByGalleryInVMAccessControlProfileOptions contains the optional parameters +// for the GalleryInVMAccessControlProfileVersionsClient.NewListByGalleryInVMAccessControlProfilePager method. +type GalleryInVMAccessControlProfileVersionsClientListByGalleryInVMAccessControlProfileOptions struct { + // placeholder for future optional parameters +} + +// GalleryInVMAccessControlProfilesClientBeginCreateOrUpdateOptions contains the optional parameters for the GalleryInVMAccessControlProfilesClient.BeginCreateOrUpdate +// method. +type GalleryInVMAccessControlProfilesClientBeginCreateOrUpdateOptions struct { + // Resumes the LRO from the provided token. + ResumeToken string +} + +// GalleryInVMAccessControlProfilesClientBeginDeleteOptions contains the optional parameters for the GalleryInVMAccessControlProfilesClient.BeginDelete +// method. +type GalleryInVMAccessControlProfilesClientBeginDeleteOptions struct { + // Resumes the LRO from the provided token. + ResumeToken string +} + +// GalleryInVMAccessControlProfilesClientBeginUpdateOptions contains the optional parameters for the GalleryInVMAccessControlProfilesClient.BeginUpdate +// method. +type GalleryInVMAccessControlProfilesClientBeginUpdateOptions struct { + // Resumes the LRO from the provided token. + ResumeToken string +} + +// GalleryInVMAccessControlProfilesClientGetOptions contains the optional parameters for the GalleryInVMAccessControlProfilesClient.Get +// method. +type GalleryInVMAccessControlProfilesClientGetOptions struct { + // placeholder for future optional parameters +} + +// GalleryInVMAccessControlProfilesClientListByGalleryOptions contains the optional parameters for the GalleryInVMAccessControlProfilesClient.NewListByGalleryPager +// method. +type GalleryInVMAccessControlProfilesClientListByGalleryOptions struct { + // placeholder for future optional parameters +} + // GallerySharingProfileClientBeginUpdateOptions contains the optional parameters for the GallerySharingProfileClient.BeginUpdate // method. type GallerySharingProfileClientBeginUpdateOptions struct { @@ -1077,6 +1143,12 @@ type SnapshotsClientListOptions struct { // placeholder for future optional parameters } +// SoftDeletedResourceClientListByArtifactNameOptions contains the optional parameters for the SoftDeletedResourceClient.NewListByArtifactNamePager +// method. +type SoftDeletedResourceClientListByArtifactNameOptions struct { + // placeholder for future optional parameters +} + // UsageClientListOptions contains the optional parameters for the UsageClient.NewListPager method. type UsageClientListOptions struct { // placeholder for future optional parameters diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/responses.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/responses.go index db4fc2bd38..5991aeb0dc 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/responses.go +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/responses.go @@ -745,6 +745,65 @@ type GalleryImagesClientUpdateResponse struct { GalleryImage } +// GalleryInVMAccessControlProfileVersionsClientCreateOrUpdateResponse contains the response from method GalleryInVMAccessControlProfileVersionsClient.BeginCreateOrUpdate. +type GalleryInVMAccessControlProfileVersionsClientCreateOrUpdateResponse struct { + // Specifies information about the gallery inVMAccessControlProfile version that you want to create or update. + GalleryInVMAccessControlProfileVersion +} + +// GalleryInVMAccessControlProfileVersionsClientDeleteResponse contains the response from method GalleryInVMAccessControlProfileVersionsClient.BeginDelete. +type GalleryInVMAccessControlProfileVersionsClientDeleteResponse struct { + // placeholder for future response values +} + +// GalleryInVMAccessControlProfileVersionsClientGetResponse contains the response from method GalleryInVMAccessControlProfileVersionsClient.Get. +type GalleryInVMAccessControlProfileVersionsClientGetResponse struct { + // Specifies information about the gallery inVMAccessControlProfile version that you want to create or update. + GalleryInVMAccessControlProfileVersion +} + +// GalleryInVMAccessControlProfileVersionsClientListByGalleryInVMAccessControlProfileResponse contains the response from method +// GalleryInVMAccessControlProfileVersionsClient.NewListByGalleryInVMAccessControlProfilePager. +type GalleryInVMAccessControlProfileVersionsClientListByGalleryInVMAccessControlProfileResponse struct { + // The List Gallery InVMAccessControlProfile Versions operation response. + GalleryInVMAccessControlProfileVersionList +} + +// GalleryInVMAccessControlProfileVersionsClientUpdateResponse contains the response from method GalleryInVMAccessControlProfileVersionsClient.BeginUpdate. +type GalleryInVMAccessControlProfileVersionsClientUpdateResponse struct { + // Specifies information about the gallery inVMAccessControlProfile version that you want to create or update. + GalleryInVMAccessControlProfileVersion +} + +// GalleryInVMAccessControlProfilesClientCreateOrUpdateResponse contains the response from method GalleryInVMAccessControlProfilesClient.BeginCreateOrUpdate. +type GalleryInVMAccessControlProfilesClientCreateOrUpdateResponse struct { + // Specifies information about the gallery inVMAccessControlProfile that you want to create or update. + GalleryInVMAccessControlProfile +} + +// GalleryInVMAccessControlProfilesClientDeleteResponse contains the response from method GalleryInVMAccessControlProfilesClient.BeginDelete. +type GalleryInVMAccessControlProfilesClientDeleteResponse struct { + // placeholder for future response values +} + +// GalleryInVMAccessControlProfilesClientGetResponse contains the response from method GalleryInVMAccessControlProfilesClient.Get. +type GalleryInVMAccessControlProfilesClientGetResponse struct { + // Specifies information about the gallery inVMAccessControlProfile that you want to create or update. + GalleryInVMAccessControlProfile +} + +// GalleryInVMAccessControlProfilesClientListByGalleryResponse contains the response from method GalleryInVMAccessControlProfilesClient.NewListByGalleryPager. +type GalleryInVMAccessControlProfilesClientListByGalleryResponse struct { + // The List Gallery InVMAccessControlProfiles operation response. + GalleryInVMAccessControlProfileList +} + +// GalleryInVMAccessControlProfilesClientUpdateResponse contains the response from method GalleryInVMAccessControlProfilesClient.BeginUpdate. +type GalleryInVMAccessControlProfilesClientUpdateResponse struct { + // Specifies information about the gallery inVMAccessControlProfile that you want to create or update. + GalleryInVMAccessControlProfile +} + // GallerySharingProfileClientUpdateResponse contains the response from method GallerySharingProfileClient.BeginUpdate. type GallerySharingProfileClientUpdateResponse struct { // Specifies information about the gallery sharing profile update. @@ -1023,6 +1082,12 @@ type SnapshotsClientUpdateResponse struct { Snapshot } +// SoftDeletedResourceClientListByArtifactNameResponse contains the response from method SoftDeletedResourceClient.NewListByArtifactNamePager. +type SoftDeletedResourceClientListByArtifactNameResponse struct { + // The List Soft-deleted Resources operation response. + GallerySoftDeletedResourceList +} + // UsageClientListResponse contains the response from method UsageClient.NewListPager. type UsageClientListResponse struct { // The List Usages operation response. diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/sharedgalleries_client.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/sharedgalleries_client.go index ee8172bae8..e93b0972af 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/sharedgalleries_client.go +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/sharedgalleries_client.go @@ -47,7 +47,7 @@ func NewSharedGalleriesClient(subscriptionID string, credential azcore.TokenCred // Get - Get a shared gallery by subscription id or tenant id. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - location - Resource location. // - galleryUniqueName - The unique name of the Shared Gallery. // - options - SharedGalleriesClientGetOptions contains the optional parameters for the SharedGalleriesClient.Get method. @@ -93,7 +93,7 @@ func (client *SharedGalleriesClient) getCreateRequest(ctx context.Context, locat return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -110,7 +110,7 @@ func (client *SharedGalleriesClient) getHandleResponse(resp *http.Response) (Sha // NewListPager - List shared galleries by subscription id or tenant id. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - location - Resource location. // - options - SharedGalleriesClientListOptions contains the optional parameters for the SharedGalleriesClient.NewListPager // method. @@ -153,7 +153,7 @@ func (client *SharedGalleriesClient) listCreateRequest(ctx context.Context, loca return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") if options != nil && options.SharedTo != nil { reqQP.Set("sharedTo", string(*options.SharedTo)) } diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/sharedgalleryimages_client.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/sharedgalleryimages_client.go index 8f0ef79cfe..1e322b89c2 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/sharedgalleryimages_client.go +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/sharedgalleryimages_client.go @@ -47,7 +47,7 @@ func NewSharedGalleryImagesClient(subscriptionID string, credential azcore.Token // Get - Get a shared gallery image by subscription id or tenant id. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - location - Resource location. // - galleryUniqueName - The unique name of the Shared Gallery. // - galleryImageName - The name of the Shared Gallery Image Definition from which the Image Versions are to be listed. @@ -98,7 +98,7 @@ func (client *SharedGalleryImagesClient) getCreateRequest(ctx context.Context, l return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -115,7 +115,7 @@ func (client *SharedGalleryImagesClient) getHandleResponse(resp *http.Response) // NewListPager - List shared gallery images by subscription id or tenant id. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - location - Resource location. // - galleryUniqueName - The unique name of the Shared Gallery. // - options - SharedGalleryImagesClientListOptions contains the optional parameters for the SharedGalleryImagesClient.NewListPager @@ -163,7 +163,7 @@ func (client *SharedGalleryImagesClient) listCreateRequest(ctx context.Context, return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") if options != nil && options.SharedTo != nil { reqQP.Set("sharedTo", string(*options.SharedTo)) } diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/sharedgalleryimageversions_client.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/sharedgalleryimageversions_client.go index 729b0e3c5d..99a9c5a403 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/sharedgalleryimageversions_client.go +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/sharedgalleryimageversions_client.go @@ -47,7 +47,7 @@ func NewSharedGalleryImageVersionsClient(subscriptionID string, credential azcor // Get - Get a shared gallery image version by subscription id or tenant id. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - location - Resource location. // - galleryUniqueName - The unique name of the Shared Gallery. // - galleryImageName - The name of the Shared Gallery Image Definition from which the Image Versions are to be listed. @@ -106,7 +106,7 @@ func (client *SharedGalleryImageVersionsClient) getCreateRequest(ctx context.Con return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -123,7 +123,7 @@ func (client *SharedGalleryImageVersionsClient) getHandleResponse(resp *http.Res // NewListPager - List shared gallery image versions by subscription id or tenant id. // -// Generated from API version 2023-07-03 +// Generated from API version 2024-03-03 // - location - Resource location. // - galleryUniqueName - The unique name of the Shared Gallery. // - galleryImageName - The name of the Shared Gallery Image Definition from which the Image Versions are to be listed. @@ -176,7 +176,7 @@ func (client *SharedGalleryImageVersionsClient) listCreateRequest(ctx context.Co return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-07-03") + reqQP.Set("api-version", "2024-03-03") if options != nil && options.SharedTo != nil { reqQP.Set("sharedTo", string(*options.SharedTo)) } diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/softdeletedresource_client.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/softdeletedresource_client.go new file mode 100644 index 0000000000..bba9f53e25 --- /dev/null +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/softdeletedresource_client.go @@ -0,0 +1,122 @@ +//go:build go1.18 +// +build go1.18 + +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. See License.txt in the project root for license information. +// Code generated by Microsoft (R) AutoRest Code Generator. DO NOT EDIT. +// Changes may cause incorrect behavior and will be lost if the code is regenerated. + +package armcompute + +import ( + "context" + "errors" + "github.com/Azure/azure-sdk-for-go/sdk/azcore" + "github.com/Azure/azure-sdk-for-go/sdk/azcore/arm" + "github.com/Azure/azure-sdk-for-go/sdk/azcore/policy" + "github.com/Azure/azure-sdk-for-go/sdk/azcore/runtime" + "net/http" + "net/url" + "strings" +) + +// SoftDeletedResourceClient contains the methods for the SoftDeletedResource group. +// Don't use this type directly, use NewSoftDeletedResourceClient() instead. +type SoftDeletedResourceClient struct { + internal *arm.Client + subscriptionID string +} + +// NewSoftDeletedResourceClient creates a new instance of SoftDeletedResourceClient with the specified values. +// - subscriptionID - Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms +// part of the URI for every service call. +// - credential - used to authorize requests. Usually a credential from azidentity. +// - options - pass nil to accept the default values. +func NewSoftDeletedResourceClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*SoftDeletedResourceClient, error) { + cl, err := arm.NewClient(moduleName, moduleVersion, credential, options) + if err != nil { + return nil, err + } + client := &SoftDeletedResourceClient{ + subscriptionID: subscriptionID, + internal: cl, + } + return client, nil +} + +// NewListByArtifactNamePager - List soft-deleted resources of an artifact in the gallery, such as soft-deleted gallery image +// version of an image. +// +// Generated from API version 2024-03-03 +// - resourceGroupName - The name of the resource group. +// - galleryName - The name of the Gallery in which the soft-deleted resources resides. +// - artifactType - The type of the artifact to be listed, such as gallery image version. +// - artifactName - The artifact name to be listed. If artifact type is Images, then the artifact name should be the gallery +// image name. +// - options - SoftDeletedResourceClientListByArtifactNameOptions contains the optional parameters for the SoftDeletedResourceClient.NewListByArtifactNamePager +// method. +func (client *SoftDeletedResourceClient) NewListByArtifactNamePager(resourceGroupName string, galleryName string, artifactType string, artifactName string, options *SoftDeletedResourceClientListByArtifactNameOptions) *runtime.Pager[SoftDeletedResourceClientListByArtifactNameResponse] { + return runtime.NewPager(runtime.PagingHandler[SoftDeletedResourceClientListByArtifactNameResponse]{ + More: func(page SoftDeletedResourceClientListByArtifactNameResponse) bool { + return page.NextLink != nil && len(*page.NextLink) > 0 + }, + Fetcher: func(ctx context.Context, page *SoftDeletedResourceClientListByArtifactNameResponse) (SoftDeletedResourceClientListByArtifactNameResponse, error) { + ctx = context.WithValue(ctx, runtime.CtxAPINameKey{}, "SoftDeletedResourceClient.NewListByArtifactNamePager") + nextLink := "" + if page != nil { + nextLink = *page.NextLink + } + resp, err := runtime.FetcherForNextLink(ctx, client.internal.Pipeline(), nextLink, func(ctx context.Context) (*policy.Request, error) { + return client.listByArtifactNameCreateRequest(ctx, resourceGroupName, galleryName, artifactType, artifactName, options) + }, nil) + if err != nil { + return SoftDeletedResourceClientListByArtifactNameResponse{}, err + } + return client.listByArtifactNameHandleResponse(resp) + }, + Tracer: client.internal.Tracer(), + }) +} + +// listByArtifactNameCreateRequest creates the ListByArtifactName request. +func (client *SoftDeletedResourceClient) listByArtifactNameCreateRequest(ctx context.Context, resourceGroupName string, galleryName string, artifactType string, artifactName string, options *SoftDeletedResourceClientListByArtifactNameOptions) (*policy.Request, error) { + urlPath := "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/galleries/{galleryName}/softDeletedArtifactTypes/{artifactType}/artifacts/{artifactName}/versions" + if client.subscriptionID == "" { + return nil, errors.New("parameter client.subscriptionID cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{subscriptionId}", url.PathEscape(client.subscriptionID)) + if resourceGroupName == "" { + return nil, errors.New("parameter resourceGroupName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{resourceGroupName}", url.PathEscape(resourceGroupName)) + if galleryName == "" { + return nil, errors.New("parameter galleryName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{galleryName}", url.PathEscape(galleryName)) + if artifactType == "" { + return nil, errors.New("parameter artifactType cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{artifactType}", url.PathEscape(artifactType)) + if artifactName == "" { + return nil, errors.New("parameter artifactName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{artifactName}", url.PathEscape(artifactName)) + req, err := runtime.NewRequest(ctx, http.MethodGet, runtime.JoinPaths(client.internal.Endpoint(), urlPath)) + if err != nil { + return nil, err + } + reqQP := req.Raw().URL.Query() + reqQP.Set("api-version", "2024-03-03") + req.Raw().URL.RawQuery = reqQP.Encode() + req.Raw().Header["Accept"] = []string{"application/json"} + return req, nil +} + +// listByArtifactNameHandleResponse handles the ListByArtifactName response. +func (client *SoftDeletedResourceClient) listByArtifactNameHandleResponse(resp *http.Response) (SoftDeletedResourceClientListByArtifactNameResponse, error) { + result := SoftDeletedResourceClientListByArtifactNameResponse{} + if err := runtime.UnmarshalAsJSON(resp, &result.GallerySoftDeletedResourceList); err != nil { + return SoftDeletedResourceClientListByArtifactNameResponse{}, err + } + return result, nil +} diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/virtualmachines_client.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/virtualmachines_client.go index 9ec32f4ea2..17e04017b8 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/virtualmachines_client.go +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/virtualmachines_client.go @@ -1219,7 +1219,8 @@ func (client *VirtualMachinesClient) performMaintenanceCreateRequest(ctx context } // BeginPowerOff - The operation to power off (stop) a virtual machine. The virtual machine can be restarted with the same -// provisioned resources. You are still charged for this virtual machine. +// provisioned resources. You are still charged for this virtual machine. NOTE: This operation is +// not allowed on a virtual machine that is being deallocated or has already been deallocated. // If the operation fails it returns an *azcore.ResponseError type. // // Generated from API version 2024-07-01 @@ -1245,7 +1246,8 @@ func (client *VirtualMachinesClient) BeginPowerOff(ctx context.Context, resource } // PowerOff - The operation to power off (stop) a virtual machine. The virtual machine can be restarted with the same provisioned -// resources. You are still charged for this virtual machine. +// resources. You are still charged for this virtual machine. NOTE: This operation is +// not allowed on a virtual machine that is being deallocated or has already been deallocated. // If the operation fails it returns an *azcore.ResponseError type. // // Generated from API version 2024-07-01 diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/virtualmachinescalesets_client.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/virtualmachinescalesets_client.go index b7cae0aa84..cd16192460 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/virtualmachinescalesets_client.go +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/virtualmachinescalesets_client.go @@ -1128,7 +1128,8 @@ func (client *VirtualMachineScaleSetsClient) performMaintenanceCreateRequest(ctx // BeginPowerOff - Power off (stop) one or more virtual machines in a VM scale set. Note that resources are still attached // and you are getting charged for the resources. Instead, use deallocate to release resources and -// avoid charges. +// avoid charges. Additionally, this operation is not allowed on virtual machines in a VM scale set that are being deallocated +// or have already been deallocated. // If the operation fails it returns an *azcore.ResponseError type. // // Generated from API version 2024-07-01 @@ -1155,7 +1156,8 @@ func (client *VirtualMachineScaleSetsClient) BeginPowerOff(ctx context.Context, // PowerOff - Power off (stop) one or more virtual machines in a VM scale set. Note that resources are still attached and // you are getting charged for the resources. Instead, use deallocate to release resources and -// avoid charges. +// avoid charges. Additionally, this operation is not allowed on virtual machines in a VM scale set that are being deallocated +// or have already been deallocated. // If the operation fails it returns an *azcore.ResponseError type. // // Generated from API version 2024-07-01 diff --git a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/virtualmachinescalesetvms_client.go b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/virtualmachinescalesetvms_client.go index f52967db5c..04ed643c8e 100644 --- a/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/virtualmachinescalesetvms_client.go +++ b/vendor/github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6/virtualmachinescalesetvms_client.go @@ -681,7 +681,8 @@ func (client *VirtualMachineScaleSetVMsClient) performMaintenanceCreateRequest(c // BeginPowerOff - Power off (stop) a virtual machine in a VM scale set. Note that resources are still attached and you are // getting charged for the resources. Instead, use deallocate to release resources and avoid -// charges. +// charges. Additionally, this operation is not allowed on a virtual machine that is being deallocated or already has been +// deallocated. // If the operation fails it returns an *azcore.ResponseError type. // // Generated from API version 2024-07-01 @@ -709,7 +710,8 @@ func (client *VirtualMachineScaleSetVMsClient) BeginPowerOff(ctx context.Context // PowerOff - Power off (stop) a virtual machine in a VM scale set. Note that resources are still attached and you are getting // charged for the resources. Instead, use deallocate to release resources and avoid -// charges. +// charges. Additionally, this operation is not allowed on a virtual machine that is being deallocated or already has been +// deallocated. // If the operation fails it returns an *azcore.ResponseError type. // // Generated from API version 2024-07-01 diff --git a/vendor/modules.txt b/vendor/modules.txt index 52a493d5a7..59565ddbf3 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -43,7 +43,7 @@ github.com/Azure/azure-sdk-for-go/sdk/internal/uuid # github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/authorization/armauthorization/v2 v2.2.0 ## explicit; go 1.18 github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/authorization/armauthorization/v2 -# github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6 v6.1.0 +# github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6 v6.2.0 ## explicit; go 1.18 github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/compute/armcompute/v6 # github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/containerregistry/armcontainerregistry v1.2.0