diff --git a/sdk/resourcemanager/resources/armdeploymentscripts/CHANGELOG.md b/sdk/resourcemanager/resources/armdeploymentscripts/CHANGELOG.md index 67f420df9d80..3b9ec47aad5f 100644 --- a/sdk/resourcemanager/resources/armdeploymentscripts/CHANGELOG.md +++ b/sdk/resourcemanager/resources/armdeploymentscripts/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History +## 0.5.1 (2022-04-18) +### Other Changes + + ## 0.5.0 (2022-04-18) ### Breaking Changes diff --git a/sdk/resourcemanager/resources/armdeploymentscripts/autorest.md b/sdk/resourcemanager/resources/armdeploymentscripts/autorest.md index 55e9dc4e0294..38567b75c1ff 100644 --- a/sdk/resourcemanager/resources/armdeploymentscripts/autorest.md +++ b/sdk/resourcemanager/resources/armdeploymentscripts/autorest.md @@ -5,9 +5,9 @@ ``` yaml azure-arm: true require: -- https://github.com/Azure/azure-rest-api-specs/blob/f92aaf88f4c9d1ffb9a014eba196d887a9288c3a/specification/resources/resource-manager/readme.md -- https://github.com/Azure/azure-rest-api-specs/blob/f92aaf88f4c9d1ffb9a014eba196d887a9288c3a/specification/resources/resource-manager/readme.go.md +- /mnt/vss/_work/1/s/azure-rest-api-specs/specification/resources/resource-manager/readme.md +- /mnt/vss/_work/1/s/azure-rest-api-specs/specification/resources/resource-manager/readme.go.md license-header: MICROSOFT_MIT_NO_VERSION -module-version: 0.5.0 +module-version: 0.5.1 package-deploymentscripts: true ``` \ No newline at end of file diff --git a/sdk/resourcemanager/resources/armdeploymentscripts/go.mod b/sdk/resourcemanager/resources/armdeploymentscripts/go.mod index 7792fda719b5..2d3e1fefae32 100644 --- a/sdk/resourcemanager/resources/armdeploymentscripts/go.mod +++ b/sdk/resourcemanager/resources/armdeploymentscripts/go.mod @@ -4,13 +4,13 @@ go 1.18 require ( github.com/Azure/azure-sdk-for-go/sdk/azcore v0.23.0 - github.com/Azure/azure-sdk-for-go/sdk/azidentity v0.14.0 github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/internal v0.3.0 github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/msi/armmsi v0.4.0 github.com/stretchr/testify v1.7.0 ) require ( + github.com/Azure/azure-sdk-for-go/sdk/azidentity v0.14.0 // indirect github.com/Azure/azure-sdk-for-go/sdk/internal v0.9.1 // indirect github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/resources/armresources v0.4.0 // indirect github.com/AzureAD/microsoft-authentication-library-for-go v0.4.0 // indirect diff --git a/sdk/resourcemanager/resources/armdeploymentscripts/ze_generated_example_deploymentscripts_client_test.go b/sdk/resourcemanager/resources/armdeploymentscripts/ze_generated_example_deploymentscripts_client_test.go deleted file mode 100644 index 27ef12ba4115..000000000000 --- a/sdk/resourcemanager/resources/armdeploymentscripts/ze_generated_example_deploymentscripts_client_test.go +++ /dev/null @@ -1,252 +0,0 @@ -//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. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armdeploymentscripts_test - -import ( - "context" - "log" - - "time" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/resources/armdeploymentscripts" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/resources/resource-manager/Microsoft.Resources/stable/2020-10-01/examples/DeploymentScripts_Create.json -func ExampleClient_BeginCreate() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - return - } - ctx := context.Background() - client, err := armdeploymentscripts.NewClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - return - } - poller, err := client.BeginCreate(ctx, - "", - "", - &armdeploymentscripts.AzurePowerShellScript{ - Identity: &armdeploymentscripts.ManagedServiceIdentity{ - Type: to.Ptr(armdeploymentscripts.ManagedServiceIdentityTypeUserAssigned), - UserAssignedIdentities: map[string]*armdeploymentscripts.UserAssignedIdentity{ - "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/scriptRG/providers/Microsoft.ManagedIdentity/userAssignedIdentities/uai": {}, - }, - }, - Kind: to.Ptr(armdeploymentscripts.ScriptTypeAzurePowerShell), - Location: to.Ptr(""), - Properties: &armdeploymentscripts.AzurePowerShellScriptProperties{ - CleanupPreference: to.Ptr(armdeploymentscripts.CleanupOptionsAlways), - Arguments: to.Ptr(""), - RetentionInterval: to.Ptr(""), - ScriptContent: to.Ptr(""), - SupportingScriptUris: []*string{ - to.Ptr("https://uri1.to.supporting.script"), - to.Ptr("https://uri2.to.supporting.script")}, - Timeout: to.Ptr(""), - AzPowerShellVersion: to.Ptr(""), - }, - }, - &armdeploymentscripts.ClientBeginCreateOptions{ResumeToken: ""}) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - return - } - res, err := poller.PollUntilDone(ctx, 30*time.Second) - if err != nil { - log.Fatalf("failed to pull the result: %v", err) - return - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/resources/resource-manager/Microsoft.Resources/stable/2020-10-01/examples/DeploymentScripts_Update.json -func ExampleClient_Update() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - return - } - ctx := context.Background() - client, err := armdeploymentscripts.NewClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - return - } - res, err := client.Update(ctx, - "", - "", - &armdeploymentscripts.ClientUpdateOptions{DeploymentScript: &armdeploymentscripts.DeploymentScriptUpdateParameter{ - Tags: map[string]*string{}, - }, - }) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - return - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/resources/resource-manager/Microsoft.Resources/stable/2020-10-01/examples/DeploymentScripts_Get.json -func ExampleClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - return - } - ctx := context.Background() - client, err := armdeploymentscripts.NewClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - return - } - res, err := client.Get(ctx, - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - return - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/resources/resource-manager/Microsoft.Resources/stable/2020-10-01/examples/DeploymentScripts_Delete.json -func ExampleClient_Delete() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - return - } - ctx := context.Background() - client, err := armdeploymentscripts.NewClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - return - } - _, err = client.Delete(ctx, - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - return - } -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/resources/resource-manager/Microsoft.Resources/stable/2020-10-01/examples/DeploymentScripts_ListBySubscription.json -func ExampleClient_NewListBySubscriptionPager() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - return - } - ctx := context.Background() - client, err := armdeploymentscripts.NewClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - return - } - pager := client.NewListBySubscriptionPager(nil) - for pager.More() { - nextResult, err := pager.NextPage(ctx) - if err != nil { - log.Fatalf("failed to advance page: %v", err) - return - } - for _, v := range nextResult.Value { - // TODO: use page item - _ = v - } - } -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/resources/resource-manager/Microsoft.Resources/stable/2020-10-01/examples/DeploymentScripts_GetLogs.json -func ExampleClient_GetLogs() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - return - } - ctx := context.Background() - client, err := armdeploymentscripts.NewClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - return - } - res, err := client.GetLogs(ctx, - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - return - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/resources/resource-manager/Microsoft.Resources/stable/2020-10-01/examples/DeploymentScripts_GetLogsDefault.json -func ExampleClient_GetLogsDefault() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - return - } - ctx := context.Background() - client, err := armdeploymentscripts.NewClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - return - } - res, err := client.GetLogsDefault(ctx, - "", - "", - &armdeploymentscripts.ClientGetLogsDefaultOptions{Tail: nil}) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - return - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/resources/resource-manager/Microsoft.Resources/stable/2020-10-01/examples/DeploymentScripts_ListByResourceGroup.json -func ExampleClient_NewListByResourceGroupPager() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - return - } - ctx := context.Background() - client, err := armdeploymentscripts.NewClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - return - } - pager := client.NewListByResourceGroupPager("", - nil) - for pager.More() { - nextResult, err := pager.NextPage(ctx) - if err != nil { - log.Fatalf("failed to advance page: %v", err) - return - } - for _, v := range nextResult.Value { - // TODO: use page item - _ = v - } - } -} diff --git a/sdk/resourcemanager/resources/armdeploymentscripts/zz_generated_constants.go b/sdk/resourcemanager/resources/armdeploymentscripts/zz_generated_constants.go index c01241128cd9..16fb15326cff 100644 --- a/sdk/resourcemanager/resources/armdeploymentscripts/zz_generated_constants.go +++ b/sdk/resourcemanager/resources/armdeploymentscripts/zz_generated_constants.go @@ -10,7 +10,7 @@ package armdeploymentscripts const ( moduleName = "armdeploymentscripts" - moduleVersion = "v0.5.0" + moduleVersion = "v0.5.1" ) // CleanupOptions - The clean up preference when the script execution gets in a terminal state. Default setting is 'Always'.