diff --git a/.azure-pipelines/powershell-core.yml b/.azure-pipelines/powershell-core.yml index 1757153461e3..3571338c9495 100644 --- a/.azure-pipelines/powershell-core.yml +++ b/.azure-pipelines/powershell-core.yml @@ -7,7 +7,7 @@ variables: LinuxAgentPoolVMImage: '' MacOSName: macOS MacOSAgentPoolName: 'Azure Pipelines' - MacOSAgentPoolVMImage: macOS-latest + MacOSAgentPoolVMImage: macOS-13 TestFramework: net6.0 TestTarget: Test Configuration: Debug diff --git a/.github/policies/resourceManagement.yml b/.github/policies/resourceManagement.yml index daca81847dac..248f1f9f6911 100644 --- a/.github/policies/resourceManagement.yml +++ b/.github/policies/resourceManagement.yml @@ -3983,6 +3983,22 @@ configuration: - azureSQLGitHub replyTemplate: Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc ${mentionees}. assignMentionees: False + - if: + - or: + - labelAdded: + label: Service Attention + - labelAdded: + label: SSH + - hasLabel: + label: Service Attention + - hasLabel: + label: SSH + then: + - mentionUsers: + mentionees: + - vthiebaut10 + replyTemplate: Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc ${mentionees}. + assignMentionees: False - if: - or: - labelAdded: @@ -4153,6 +4169,22 @@ configuration: - Shipra1Mishra replyTemplate: Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc ${mentionees}. assignMentionees: False + - if: + - or: + - labelAdded: + label: Service Attention + - labelAdded: + label: Traffic Collector + - hasLabel: + label: Service Attention + - hasLabel: + label: Traffic Collector + then: + - mentionUsers: + mentionees: + - rmodh + replyTemplate: Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc ${mentionees}. + assignMentionees: False - if: - or: - labelAdded: diff --git a/ChangeLog.md b/ChangeLog.md index 03394a9c1c30..b85c1d992169 100644 --- a/ChangeLog.md +++ b/ChangeLog.md @@ -63,14 +63,6 @@ #### Az.RecoveryServices 7.2.0 * Fixed bug for making RecoveryAzureStorageAccountId parameter optional in 'New-ASRReplicationProtectedItem' cmdlet of H2A. -#### Az.RedisEnterpriseCache 1.3.0 -* Added support for using Microsoft Entra token-based authentication. -* Added the new properties of Cluster: highAvailability and redundancyMode. -* Added new product SKUs. -* Added the new properties of Database: accessKeysAuthentication. -* Added Invoke-AzRedisEnterpriseCacheForceDatabaseLinkToReplicationGroup to force link geo replicated caches. -* Added Update-AzRedisEnterpriseCacheDatabaseDbRedisVersion to upgrade the redis database version directly. - #### Az.Resources 7.5.0 * Added 'ResourceSelector' and 'Override' parameters to 'New/Update-AzPolicyAssignment'. * Added 'ResourceSelector' parameter to 'New/Update-AzPolicyExemption'. diff --git a/documentation/SyntaxChangeLog/SyntaxChangeLog-Az12.md b/documentation/SyntaxChangeLog/SyntaxChangeLog-Az12.md index 4177723fa5b4..eacccd0900b5 100644 --- a/documentation/SyntaxChangeLog/SyntaxChangeLog-Az12.md +++ b/documentation/SyntaxChangeLog/SyntaxChangeLog-Az12.md @@ -40,10 +40,6 @@ * Modified cmdlet `Set-AzNetworkWatcherFlowLog` - Added parameters `-EnabledFilteringCriteria`, `-UserAssignedIdentityId` * Added cmdlet `Get-AzBastionShareableLink`, `New-AzBastionShareableLink`, `Remove-AzBastionShareableLink` -#### Az.RedisEnterpriseCache 1.3.0 -* Modified cmdlet `Update-AzRedisEnterpriseCache` - - Added parameter `-HighAvailability` -* Added cmdlet `Get-AzRedisEnterpriseCacheAccessPolicyAssignment`, `Invoke-AzRedisEnterpriseCacheForceDatabaseLinkToReplicationGroup`, `New-AzRedisEnterpriseCacheAccessPolicyAssignment`, `Remove-AzRedisEnterpriseCacheAccessPolicyAssignment`, `Update-AzRedisEnterpriseCacheDatabaseDbRedisVersion` #### Az.Resources 7.5.0 * Modified cmdlet `New-AzPolicyAssignment` - Added parameters `-Override`, `-ResourceSelector` diff --git a/documentation/azure-powershell-modules.md b/documentation/azure-powershell-modules.md index 228ced5f82e3..cd3650d0315c 100644 --- a/documentation/azure-powershell-modules.md +++ b/documentation/azure-powershell-modules.md @@ -80,6 +80,7 @@ | ElasticSan on Azure | `Az.ElasticSan` | [![ElasticSan]][ElasticSanGallery] | [Changelog][ElasticSanChangeLog] | | Event Grid | `Az.EventGrid` | [![EventGrid]][EventGridGallery] | [Changelog][EventGridChangeLog] | | Event Hubs | `Az.EventHub` | [![EventHub]][EventHubGallery] | [Changelog][EventHubChangeLog] | +| Fabric | `Fabric` | [![Fabric]][FabricGallery] | [Changelog][FabricChangeLog] | | FirmwareAnalysis | `FirmwareAnalysis` | [![FirmwareAnalysis]][FirmwareAnalysisGallery] | [Changelog][FirmwareAnalysisChangeLog] | | Fleet | `Az.Fleet` | [![Fleet]][FleetGallery] | [Changelog][FleetChangeLog] | | Fluid Relay | `Az.FluidRelay` | [![FluidRelay]][FluidRelayGallery] | [Changelog][FluidRelayChangeLog] | @@ -99,6 +100,7 @@ | IoT Hub | `Az.IotHub` | [![IotHub]][IotHubGallery] | [Changelog][IotHubChangeLog] | | Key Vault | `Az.KeyVault` | [![KeyVault]][KeyVaultGallery] | [Changelog][KeyVaultChangeLog] | | Kubernetes Configuration | `Az.KubernetesConfiguration` | [![KubernetesConfiguration]][KubernetesConfigurationGallery] | [Changelog][KubernetesConfigurationChangeLog] | +| Kubernetes Runtime | `Az.KubernetesRuntime` | [![KubernetesRuntime]][KubernetesRuntimeGallery] | [Changelog][KubernetesRuntimeChangeLog] | | Kusto | `Az.Kusto` | [![Kusto]][KustoGallery] | [Changelog][KustoChangeLog] | | Lab Services | `Az.LabServices` | [![LabServices]][LabServicesGallery] | [Changelog][LabServicesChangeLog] | | Load Testing | `Az.LoadTesting` | [![LoadTesting]][LoadTestingGallery] | [Changelog][LoadTestingChangeLog] | @@ -176,6 +178,7 @@ | Synapse Analytics | `Az.Synapse` | [![Synapse]][SynapseGallery] | [Changelog][SynapseChangeLog] | | Time Series Insights | `Az.TimeSeriesInsights` | [![TimeSeriesInsights]][TimeSeriesInsightsGallery] | [Changelog][TimeSeriesInsightsChangeLog] | | Traffic Manager | `Az.TrafficManager` | [![TrafficManager]][TrafficManagerGallery] | [Changelog][TrafficManagerChangeLog] | +| Terraform | `Az.Terraform` | [![Terraform]][TerraformGallery] | [Changelog][TerraformChangeLog] | | Azure VMware Solution | `Az.VMware` | [![VMware]][VMwareGallery] | [Changelog][VMwareChangeLog] | | Voice Services | `Az.VoiceServices` | [![VoiceServices]][VMwareGallery] | [Changelog][VoiceServicesChangeLog] | | Web App Service | `Az.Websites` | [![Websites]][WebsitesGallery] | [Changelog][WebsitesChangeLog] | @@ -258,6 +261,7 @@ [ElasticSan]: https://img.shields.io/powershellgallery/v/Az.ElasticSan.svg?style=flat-square&label=Az.ElasticSan [EventGrid]: https://img.shields.io/powershellgallery/v/Az.EventGrid.svg?style=flat-square&label=Az.EventGrid [EventHub]: https://img.shields.io/powershellgallery/v/Az.EventHub.svg?style=flat-square&label=Az.EventHub +[Fabric]: https://img.shields.io/powershellgallery/v/Az.Fabric.svg?style=flat-square&label=Az.Fabric [FirmwareAnalysis]: https://img.shields.io/powershellgallery/v/Az.FirmwareAnalysis.svg?style=flat-square&label=Az.FirmwareAnalysis [Fleet]: https://img.shields.io/powershellgallery/v/Az.Fleet.svg?style=flat-square&label=Az.Fleet [FluidRelay]: https://img.shields.io/powershellgallery/v/Az.FluidRelay.svg?style=flat-square&label=Az.FluidRelay @@ -277,6 +281,7 @@ [IotHub]: https://img.shields.io/powershellgallery/v/Az.IotHub.svg?style=flat-square&label=Az.IotHub [KeyVault]: https://img.shields.io/powershellgallery/v/Az.KeyVault.svg?style=flat-square&label=Az.KeyVault [KubernetesConfiguration]: https://img.shields.io/powershellgallery/v/Az.KubernetesConfiguration.svg?style=flat-square&label=Az.KubernetesConfiguration +[KubernetesRuntime]: https://img.shields.io/powershellgallery/v/Az.KubernetesRuntime.svg?style=flat-square&label=Az.KubernetesRuntime [Kusto]: https://img.shields.io/powershellgallery/v/Az.Kusto.svg?style=flat-square&label=Az.Kusto [LabServices]: https://img.shields.io/powershellgallery/v/Az.LabServices.svg?style=flat-square&label=Az.LabServices [LoadTesting]: https://img.shields.io/powershellgallery/v/Az.LoadTesting.svg?style=flat-square&label=Az.LoadTesting @@ -354,6 +359,7 @@ [Synapse]: https://img.shields.io/powershellgallery/v/Az.Synapse.svg?style=flat-square&label=Az.Synapse [TimeSeriesInsights]: https://img.shields.io/powershellgallery/v/Az.TimeSeriesInsights.svg?style=flat-square&label=Az.TimeSeriesInsights [TrafficManager]: https://img.shields.io/powershellgallery/v/Az.TrafficManager.svg?style=flat-square&label=Az.TrafficManager +[Terraform]: https://img.shields.io/powershellgallery/v/Az.Terraform.svg?style=flat-square&label=Az.Terraform [VMware]: https://img.shields.io/powershellgallery/v/Az.VMware.svg?style=flat-square&label=Az.VMware [VoiceServices]: https://img.shields.io/powershellgallery/v/Az.VoiceServices.svg?style=flat-square&label=Az.VoiceServices [Websites]: https://img.shields.io/powershellgallery/v/Az.Websites.svg?style=flat-square&label=Az.Websites @@ -432,6 +438,7 @@ [ElasticSanGallery]: https://www.powershellgallery.com/packages/Az.ElasticSan/ [EventGridGallery]: https://www.powershellgallery.com/packages/Az.EventGrid/ [EventHubGallery]: https://www.powershellgallery.com/packages/Az.EventHub/ +[FabricGallery]: https://www.powershellgallery.com/packages/Az.Fabric/ [FirmwareAnalysisGallery]: https://www.powershellgallery.com/packages/Az.FirmwareAnalysis/ [FleetGallery]: https://www.powershellgallery.com/packages/Az.Fleet/ [FluidRelayGallery]: https://www.powershellgallery.com/packages/Az.FluidRelay/ @@ -451,6 +458,7 @@ [IotHubGallery]: https://www.powershellgallery.com/packages/Az.IotHub/ [KeyVaultGallery]: https://www.powershellgallery.com/packages/Az.KeyVault/ [KubernetesConfigurationGallery]: https://www.powershellgallery.com/packages/Az.KubernetesConfiguration/ +[KubernetesRuntimeGallery]: https://www.powershellgallery.com/packages/Az.KubernetesRuntime/ [KustoGallery]: https://www.powershellgallery.com/packages/Az.Kusto/ [LabServicesGallery]: https://www.powershellgallery.com/packages/Az.LabServices/ [LoadTestingGallery]: https://www.powershellgallery.com/packages/Az.LoadTesting/ @@ -528,6 +536,7 @@ [SynapseGallery]: https://www.powershellgallery.com/packages/Az.Synapse/ [TimeSeriesInsightsGallery]: https://www.powershellgallery.com/packages/Az.TimeSeriesInsights/ [TrafficManagerGallery]: https://www.powershellgallery.com/packages/Az.TrafficManager/ +[TerraformGallery]: https://www.powershellgallery.com/packages/Az.Terraform/ [VMwareGallery]: https://www.powershellgallery.com/packages/Az.VMware/ [VoiceServicesGallery]: https://www.powershellgallery.com/packages/Az.VoiceServices/ [WebsitesGallery]: https://www.powershellgallery.com/packages/Az.Websites/ @@ -604,6 +613,7 @@ [ElasticSanChangeLog]: ../src/ElasticSan/ElasticSan/ChangeLog.md [EventGridChangeLog]: ../src/EventGrid/EventGrid/ChangeLog.md [EventHubChangeLog]: ../src/EventHub/EventHub/ChangeLog.md +[FabricChangeLog]: ../src/Fabric/Fabric/ChangeLog.md [FirmwareAnalysisChangeLog]: ../src/FirmwareAnalysis/FirmwareAnalysis/ChangeLog.md [FleetChangeLog]: ../src/Fleet/Fleet/ChangeLog.md [FluidRelayChangeLog]: ../src/FluidRelay/FluidRelay/ChangeLog.md @@ -623,6 +633,7 @@ [IotHubChangeLog]: ../src/IotHub/IotHub/ChangeLog.md [KeyVaultChangeLog]: ../src/KeyVault/KeyVault/ChangeLog.md [KubernetesConfigurationChangeLog]: ../src/KubernetesConfiguration/KubernetesConfiguration/ChangeLog.md +[KubernetesRuntimeChangeLog]: ../src/KubernetesRuntime/KubernetesRuntime/ChangeLog.md [KustoChangeLog]: ../src/Kusto/Kusto/ChangeLog.md [LabServicesChangeLog]: ../src/LabServices/LabServices/ChangeLog.md [LoadTestingChangeLog]: ../src/LoadTesting/LoadTesting/ChangeLog.md @@ -700,6 +711,7 @@ [SynapseChangeLog]: ../src/Synapse/Synapse/ChangeLog.md [TimeSeriesInsightsChangeLog]: ../src/TimeSeriesInsights/TimeSeriesInsights/ChangeLog.md [TrafficManagerChangeLog]: ../src/TrafficManager/TrafficManager/ChangeLog.md +[TerraformChangeLog]: ../src/Terraform/Terraform/ChangeLog.md [VMwareChangeLog]: ../src/VMware/VMware/ChangeLog.md [VoiceServicesChangeLog]: ../src/VoiceServices/VoiceServices/ChangeLog.md [WebsitesChangeLog]: ../src/Websites/Websites/ChangeLog.md diff --git a/documentation/breaking-changes/breaking-changes-in-generated-modules-due-to-codegen-tool-upgrade-from-v3-to-v4.md b/documentation/breaking-changes/breaking-changes-in-generated-modules-due-to-codegen-tool-upgrade-from-v3-to-v4.md new file mode 100644 index 000000000000..a5eb63601c6a --- /dev/null +++ b/documentation/breaking-changes/breaking-changes-in-generated-modules-due-to-codegen-tool-upgrade-from-v3-to-v4.md @@ -0,0 +1,42 @@ +# Breaking Changes in Generated Modules Due to AutoRest.PowerShell Upgrade from v3 to v4 + +We are moving forward with using the new version of the code generation tool, AutoRest.PowerShell v4, to take advantage of the features offered by the latest version. The redesign of the generated code to support new user requirements in this version inevitably introduces some breaking changes. + +Below, we list the potential breaking changes from the perspective of users that may occur when upgrading the code generation tool for Azure PowerShell modules. + +**Note: The breaking changes listed below may not apply universally to all generated modules. The occurrence of these breaking changes also depends on the specific configurations used when generating Azure PowerShell modules with AutoRest.PowerShell v4. For detailed information on which breaking changes may occur, please refer to the [breaking change list](https://learn.microsoft.com/powershell/azure/upcoming-breaking-changes) for the specific module.** + +## List Replaces Array in Generated C# Classes + +We now generate collection-like properties as [`List`](https://learn.microsoft.com/dotnet/api/system.collections.generic.list-1) instead of [`Array`](https://learn.microsoft.com/en-us/dotnet/api/system.array) in the models. This is because `List` is dynamic that it allows appending/deleting elements, while `Array` is fixed-size hence difficult to edit. + +### How to Mitigate the Impact of Breaking Changes + +* "Use methods from List to replace methods from Array, for example: use count instead of Length to retrieve the number of elements +* Use the ToArray function if conversion to a fixed-size array is needed + +## Use Primitive Types for Enum Instead of Struct + +We used to generate a struct for [enum](https://github.com/Azure/autorest/blob/main/docs/extensions/readme.md#x-ms-enum) to support tab completer for parameters. This design has been abandoned due to its limitation of only supporting enums with string type. + +### How to Mitigate the Impact of Breaking Changes + +Generally, this change will not cause a breaking change for users. In modules generated by older versions, users typically use primitive types, and the generated struct includes a converter that transforms these primitive types into the struct. The only requirement for users is to avoid using Microsoft.Azure.PowerShell.Cmdlets.{module}.Support.* directly. + +## Breaking Changes Due to Bug Fixes + +### Removal of PassThru for Certain Cmdlets + +`-PassThru` is a switch parameter that we add to cmdlets that don't have outputs to enable the pipline functionality. In AutoRest.PowerShell v3, `-PassThru` was incorrectly added to some cmdlets that do have outputs. This is fixed in v4 and those extra `-PassThru` parameters are removed. + +#### How to Mitigate the Impact of Breaking Changes + +Discontinue using the `PassThru` parameter for these cmdlets. Be careful that by doing so the output may change. + +### Removal of Readonly Parameters + +If a property is marked `"x-ms-mutability": ["read"]` in the OpenAPI spec, it means it should only appear in the output but never as an input parameter. However, in AutoRest.PowerShell v3, such kind of readonly parameters were incorrectly generated for cmdlets. + +#### How to Mitigate the Impact of Breaking Changes + +It's safe to simply remove these Readonly parameters, as they are ignored by the service. \ No newline at end of file diff --git a/documentation/breaking-changes/upcoming-breaking-changes.md b/documentation/breaking-changes/upcoming-breaking-changes.md index 80519af20daa..97f1a9ac0f47 100644 --- a/documentation/breaking-changes/upcoming-breaking-changes.md +++ b/documentation/breaking-changes/upcoming-breaking-changes.md @@ -2,6 +2,11 @@ ## Az.Accounts +### `Resolve-AzError` + +- The alias `Resolve-Error` will be removed. Please use `Resolve-AzError` instead. + - This change is expected to take effect from Az.Accounts version: 4.0.0 and Az version: 13.0.0 + ### `Get-AzAccessToken` - Cmdlet breaking-change will happen to all parameter sets diff --git a/src/Accounts/Accounts/ChangeLog.md b/src/Accounts/Accounts/ChangeLog.md index 12cb5d0d89bd..cc1d71f68e78 100644 --- a/src/Accounts/Accounts/ChangeLog.md +++ b/src/Accounts/Accounts/ChangeLog.md @@ -19,6 +19,8 @@ --> ## Upcoming Release +* Added breaking change preannouncement for the removal of alias `Resolve-Error`. #26189 +* Integrated new detection library to expand the scope of secrets. ## Version 3.0.4 * Added customized UserAgent for ARM telemetry. @@ -26,7 +28,6 @@ * Updated `Connect-AzAccount` to fix a display issue in PowerShell ISE [#24556]. * Updated the reference of Azure PowerShell Common to 1.3.100-preview. * Used Azure.Identity and Azure.Core directly for client assertion [#22628]. -* Integrated new detection library to expand the scope of secrets. ## Version 3.0.3 * Reduced the frequency of displaying sign-in announcement messages. diff --git a/src/Accounts/Accounts/Errors/ResolveError.cs b/src/Accounts/Accounts/Errors/ResolveError.cs index 4e6ef25d55c5..5c6db96384ae 100644 --- a/src/Accounts/Accounts/Errors/ResolveError.cs +++ b/src/Accounts/Accounts/Errors/ResolveError.cs @@ -30,6 +30,7 @@ namespace Microsoft.Azure.Commands.Profile.Errors [OutputType(typeof(AzureErrorRecord))] [OutputType(typeof(AzureExceptionRecord))] [OutputType(typeof(AzureRestExceptionRecord))] + [GenericBreakingChangeWithVersion("The alias 'Resolve-Error' will be removed. Please use 'Resolve-AzError' instead.", "13.0.0", "4.0.0")] public class ResolveError : AzureRMCmdlet { public const string AnyErrorParameterSet = "AnyErrorParameterSet"; diff --git a/src/Compute/Compute/help/New-AzGalleryImageVersion.md b/src/Compute/Compute/help/New-AzGalleryImageVersion.md index 04c513dbeddf..cbd8596a6b52 100644 --- a/src/Compute/Compute/help/New-AzGalleryImageVersion.md +++ b/src/Compute/Compute/help/New-AzGalleryImageVersion.md @@ -38,8 +38,8 @@ $galleryName = "myGallery" $galleryImageDefinitionName = "myImage" $galleryImageVersionName = "1.0.0" $location = "eastus" -$sourceImageId = "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myVMRG/providers/Microsoft.Compute/virtualMachines/myVM" -New-AzGalleryImageVersion -ResourceGroupName $rgName -GalleryName $galleryName -GalleryImageDefinitionName $galleryImageDefinitionName -Name $galleryImageVersionName -Location $location -SourceImageId $sourceImageId +$sourceImageVMId = "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myVMRG/providers/Microsoft.Compute/virtualMachines/myVM" +New-AzGalleryImageVersion -ResourceGroupName $rgName -GalleryName $galleryName -GalleryImageDefinitionName $galleryImageDefinitionName -Name $galleryImageVersionName -Location $location -SourceImageVMId $sourceImageVMId ``` Add a new image version from a virtual machine into the image definition. diff --git a/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/DEVELOP.md b/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/DEVELOP.md new file mode 100644 index 000000000000..f9974023d076 --- /dev/null +++ b/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/DEVELOP.md @@ -0,0 +1,51 @@ +# Develpoing ConnectedKubernetes Powershell Cmdlets +> These notes are intended to compliment and extend the common instructions for this process. If you spot a sensible common location where part of this document could live, please do move the information out of here. + +# Overview +## Why Custom Cmdlets? +Powerhsll cmdlets can be created almost totally automatically for many products but ConnectedKubernetes is special. The standard cmdlet interations are one or more ([Swagger]) REST API exchanges with Azure but ConnectedKubernetes also has to install Azure Arc support into a Kubernetes cluster and this requires work to be performed using [helm]. + +For this reason, the ConnectedKubernetes cmdlets have two or more steps such as: +- Interact with Azure using the REST APIs; this often involves just calling the autogenerated cmdlets +- Now interact with Kubernetes using [helm]. + +## (Part) Autogeneration Process +The autogeneration process uses [autorest.powershell], an [autorest] extension for creating Powershell cmdlets based on a (Swagger) REST API definition. this is typically as follows: + +1. Carefully craft your [Swagger] definition of the REST API +1. Read the [Quickstart for Azure PowerShell development using code generator] +1. Clone the [azure-powershell] repo +1. Create a develpoment branch based on the `generate` branch **and not based on `main`**! +1. Run the [autorest] Docker image; if you have no local image for [autorest], refer to +1. Run [autorest] to generate configuration and files that will result in the autogenerated cmdlets +1. Run the build process (`pwsh build-module.ps1`) which completes the build process. + +### Building the [autorest] Docker image +> Do **NOT** build an [autorest] image based on the Dockerfile contained in the `tools/autorest` directory below the [azure-powershell] repo as this does not produce a working image! + +- Clone the [autorest.powershell] repo +- Navigate to the `tools/docker` directory +- Follow the instructions in the README file in that directory + +## Special Aspects for ConnectedKubernetes +The autogenerated cmdlets are created in C# with Powershell wrappers that are placed into the `internal` folder. This is because we are **NOT** exposing the autogenerated functions to the user, rather er export our custom versions. +> As described earlier, the custom versions often call-through to the autogenerated version to perform the ARM REST API portion of their work. + +### Gotchas +#### You Want a New Cmdlet? +If you are creating a whole new command, then you need to get the [autorest] process and the build process to work together to create the underlying `internal` command for you and this is not trivial. + +When we tried to add the `Set-` cmdlet, we found it never appeared but eventually we discovered these nuggets of knowledge. +- [autorest] will look at the `operationId` field in the [Swagger] for each REST API method and determine what commands to create. So in our case `ConnectedCluster_Create` only causes `New-` cmdlets to be created and we had to update the [Swagger] to say `ConnectedCluster_CreateOrUpdate` before any `Set-` cmdlets were created +- The `internal` cmdlets are really just Powershell wrappers but these are not created until the `pwsh build-module-ps1` step +- Between the steps above sits the [autorest] configuration found in the XML at the end of [README.md]. This does stuff like: + - Stops the generation of various versions of cmdlets that are not required + - **hides** the autogenerated cmdlets, which is what causes them to be created in `internal`; we had to add `set` to the list of cmdlets so hidden before the `internal` `Set-` cmdlet appeared. + +[autorest.powershell]: https://github.com/Azure/autorest.powershell +[autorest]: https://github.com/Azure/autorest +[helm]: https://helm.sh/ +[Swagger]: https://swagger.io/ +[README.md]: ./README.md +[Quickstart for Azure PowerShell development using code generator]: https://eng.ms/docs/cloud-ai-platform/azure-core/azure-management-and-platforms/control-plane-bburns/azure-cli-tools-azure-cli-powershell-and-terraform/azure-cli-tools/onboarding/azurepowershell/quickstart_codegen +[azure-powershell]: https://github.com/azure/azure-powershell \ No newline at end of file diff --git a/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/New-AzConnectedKubernetes.ps1 b/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/New-AzConnectedKubernetes.ps1 index ae5f195c02cc..55b709814174 100644 --- a/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/New-AzConnectedKubernetes.ps1 +++ b/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/New-AzConnectedKubernetes.ps1 @@ -319,7 +319,7 @@ function New-AzConnectedKubernetes { $Null = $PSBoundParameters.Remove('KubeConfig') } elseif (Test-Path Env:KUBECONFIG) { - $KubeConfig = Get-ChildItem -Path Env:KUBECONFIG + $KubeConfig = Get-ChildItem -Path $Env:KUBECONFIG } elseif (Test-Path Env:Home) { $KubeConfig = Join-Path -Path $Env:Home -ChildPath '.kube' | Join-Path -ChildPath 'config' @@ -364,7 +364,11 @@ function New-AzConnectedKubernetes { $PSBoundParameters.Add('IdentityType', $IdentityType) #Region check helm install - Confirm-HelmVersion -KubeConfig $KubeConfig + Confirm-HelmVersion ` + -KubeConfig $KubeConfig ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) + #EndRegion $helmClientLocation = 'helm' @@ -421,8 +425,13 @@ function New-AzConnectedKubernetes { if ($PSVersionTable.PSVersion.Major -eq 5) { try { . "$PSScriptRoot/helpers/RSAHelper.ps1" - $AgentPublicKey = ExportRSAPublicKeyBase64($RSA) - $AgentPrivateKey = ExportRSAPrivateKeyBase64($RSA) + $AgentPublicKey = ExportRSAPublicKeyBase64($RSA) ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) + $AgentPrivateKey = ExportRSAPrivateKeyBase64($RSA) ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) + $AgentPrivateKey = "-----BEGIN RSA PRIVATE KEY-----`n" + $AgentPrivateKey + "`n-----END RSA PRIVATE KEY-----" } catch { @@ -541,15 +550,25 @@ function New-AzConnectedKubernetes { # A lot of what follows relies on knowing the cloud we are using and the # various endpoints so get that information now. - $cloudMetadata = Get-AzCloudMetadata + $cloudMetadata = Get-AzCloudMetadata ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) # Perform DP health check - $configDpinfo = Get-ConfigDPEndpoint -location $Location -Cloud $cloudMetadata + $configDpinfo = Get-ConfigDPEndpoint ` + -location $Location ` + -Cloud $cloudMetadata ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) + $configDPEndpoint = $configDpInfo.configDPEndpoint # If the health check fails (not 200 response), an exception is thrown # so we can ignore the output. - $null = Invoke-ConfigDPHealthCheck -configDPEndpoint $configDPEndpoint + $null = Invoke-ConfigDPHealthCheck ` + -configDPEndpoint $configDPEndpoint ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) # This call does the "pure ARM" update of the ARM objects. Write-Debug "Writing Connected Kubernetes ARM objects." @@ -586,7 +605,12 @@ function New-AzConnectedKubernetes { # needs to change and not the Powershell script (or az CLI). # # Do not send protected settings to CCRP - $arcAgentryConfigs = ConvertTo-ArcAgentryConfiguration -ConfigurationSetting $ConfigurationSetting -RedactedProtectedConfiguration @{} -CCRP $true + $arcAgentryConfigs = ConvertTo-ArcAgentryConfiguration ` + -ConfigurationSetting $ConfigurationSetting ` + -RedactedProtectedConfiguration @{} ` + -CCRP $true ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) # It is possible to set an empty value for these parameters and then # the code above gets skipped but we still need to remove the empty @@ -601,6 +625,7 @@ function New-AzConnectedKubernetes { $PSBoundParameters.Add('ArcAgentryConfiguration', $arcAgentryConfigs) Write-Output "Creating 'Kubernetes - Azure Arc' object in Azure" + Write-Debug "PSBoundParameters: $PSBoundParameters" $Response = Az.ConnectedKubernetes.internal\New-AzConnectedKubernetes @PSBoundParameters if ((-not $WhatIfPreference) -and (-not $Response)) { @@ -608,7 +633,12 @@ function New-AzConnectedKubernetes { return } - $arcAgentryConfigs = ConvertTo-ArcAgentryConfiguration -ConfigurationSetting $ConfigurationSetting -RedactedProtectedConfiguration $RedactedProtectedConfiguration -CCRP $false + $arcAgentryConfigs = ConvertTo-ArcAgentryConfiguration ` + -ConfigurationSetting $ConfigurationSetting ` + -RedactedProtectedConfiguration $RedactedProtectedConfiguration ` + -CCRP $false ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) # Convert the $Response object into a nested hashtable. @@ -643,7 +673,7 @@ function New-AzConnectedKubernetes { Write-Debug "OCI Artifact location: ${helmValuesDp.repositoryPath}." $registryPath = if ($env:HELMREGISTRY) { $env:HELMREGISTRY } else { $helmValuesDp.repositoryPath } - Write-Debug "RegistryPath: ${registryPath}." + Write-Debug "RegistryPath: ${registryPath}" $helmValuesContent = $helmValuesDp.helmValuesContent Write-Debug "Helm values: ${helmValuesContent}." @@ -654,7 +684,7 @@ function New-AzConnectedKubernetes { # hashtable. $optionsFromDp = "" foreach ($field in $helmValuesContent.PSObject.Properties) { - if($field.Value.StartsWith($ProtectedSettingsPlaceholderValue)){ + if ($field.Value.StartsWith($ProtectedSettingsPlaceholderValue)) { $parsedValue = $field.Value.Split(":") # "${ProtectedSettingsPlaceholderValue}:${feature}:${setting}" $field.Value = $ConfigurationProtectedSetting[$parsedValue[1]][$parsedValue[2]] @@ -670,9 +700,15 @@ function New-AzConnectedKubernetes { # Get helm chart path (within the OCI registry). if ($PSCmdlet.ShouldProcess("configDP", "request Helm chart")) { - $chartPath = Get-HelmChartPath -registryPath $registryPath -kubeConfig $KubeConfig -kubeContext $KubeContext -helmClientLocation $HelmClientLocation + $chartPath = Get-HelmChartPath ` + -registryPath $registryPath ` + -kubeConfig $KubeConfig ` + -kubeContext $KubeContext ` + -helmClientLocation $HelmClientLocation ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) if (Test-Path Env:HELMCHART) { - $ChartPath = Get-ChildItem -Path Env:HELMCHART + $ChartPath = Get-ChildItem -Path $Env:HELMCHART } } @@ -722,9 +758,11 @@ function New-AzConnectedKubernetes { if ($ExistConnectedKubernetes.ArcAgentProfileAgentState -eq "Succeeded") { Write-Output "Cluster configuration succeeded." - } elseif ($ExistConnectedKubernetes.ArcAgentProfileAgentState -eq "Failed") { + } + elseif ($ExistConnectedKubernetes.ArcAgentProfileAgentState -eq "Failed") { Write-Error "Cluster configuration failed." - } else { + } + else { Write-Error "Cluster configuration timed out after 60 minutes." } } diff --git a/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/Remove-AzConnectedKubernetes.ps1 b/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/Remove-AzConnectedKubernetes.ps1 index b85ac325af87..f41edf4a37e6 100644 --- a/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/Remove-AzConnectedKubernetes.ps1 +++ b/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/Remove-AzConnectedKubernetes.ps1 @@ -156,7 +156,7 @@ param( if ($PSBoundParameters.ContainsKey('KubeConfig')) { $Null = $PSBoundParameters.Remove('KubeConfig') } elseif (Test-Path Env:KUBECONFIG) { - $KubeConfig = Get-ChildItem -Path Env:KUBECONFIG + $KubeConfig = Get-ChildItem -Path $Env:KUBECONFIG } elseif (Test-Path Env:Home) { $KubeConfig = Join-Path -Path $Env:Home -ChildPath '.kube' | Join-Path -ChildPath 'config' } else { @@ -175,7 +175,10 @@ param( #Region check helm install try { - Set-HelmClientLocation + Set-HelmClientLocation ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) + $HelmVersion = helm version --short --kubeconfig $KubeConfig if ($HelmVersion.Contains("v2")) { Write-Error "Helm version 3+ is required. Ensure that you have installed the latest version of Helm. Learn more at https://aka.ms/arc/k8s/onboarding-helm-install" @@ -187,7 +190,10 @@ param( #Endregion #Region get release namespace - $ReleaseInstallNamespace = Get-ReleaseInstallNamespace + $ReleaseInstallNamespace = Get-ReleaseInstallNamespace ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) + $ReleaseNamespace = $null try { $ReleaseNamespace = (helm status azure-arc -o json --kubeconfig $KubeConfig --kube-context $KubeContext -n $ReleaseInstallNamespace | ConvertFrom-Json).namespace diff --git a/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/Set-AzConnectedKubernetes.ps1 b/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/Set-AzConnectedKubernetes.ps1 index 04e622568316..513793adf1cd 100644 --- a/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/Set-AzConnectedKubernetes.ps1 +++ b/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/Set-AzConnectedKubernetes.ps1 @@ -374,7 +374,7 @@ function Set-AzConnectedKubernetes { $Null = $PSBoundParameters.Remove('KubeConfig') } elseif (Test-Path Env:KUBECONFIG) { - $KubeConfig = Get-ChildItem -Path Env:KUBECONFIG + $KubeConfig = Get-ChildItem -Path $Env:KUBECONFIG } elseif (Test-Path Env:Home) { $KubeConfig = Join-Path -Path $Env:Home -ChildPath '.kube' | Join-Path -ChildPath 'config' @@ -452,7 +452,10 @@ function Set-AzConnectedKubernetes { $PSBoundParameters.Add('IdentityType', $IdentityType) #Region check helm install - Confirm-HelmVersion -KubeConfig $KubeConfig + Confirm-HelmVersion ` + -KubeConfig $KubeConfig ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) #EndRegion $helmClientLocation = 'helm' @@ -542,12 +545,12 @@ function Set-AzConnectedKubernetes { # If the user does not provide proxy settings, or configuration settings, we shall use arc config of existing object $userProvidedArcConfiguration = ( ($null -ne $InputObject) -and ($InputObject.ArcAgentryConfiguration.Length > 0) ` - -and (-not ([string]::IsNullOrEmpty($HttpProxy))) ` - -and (-not ([string]::IsNullOrEmpty($HttpsProxy))) ` - -and (-not ([string]::IsNullOrEmpty($NoProxy))) ` - -and ((-not ([string]::IsNullOrEmpty($ProxyCert)))) ` - -and ($PSBoundParameters.ContainsKey('ConfigurationSetting')) ` - -and ($PSBoundParameters.ContainsKey('ConfigurationProtectedSetting'))) + -and (-not ([string]::IsNullOrEmpty($HttpProxy))) ` + -and (-not ([string]::IsNullOrEmpty($HttpsProxy))) ` + -and (-not ([string]::IsNullOrEmpty($NoProxy))) ` + -and ((-not ([string]::IsNullOrEmpty($ProxyCert)))) ` + -and ($PSBoundParameters.ContainsKey('ConfigurationSetting')) ` + -and ($PSBoundParameters.ContainsKey('ConfigurationProtectedSetting'))) if ($null -eq $ConfigurationSetting) { $ConfigurationSetting = @{} @@ -613,15 +616,25 @@ function Set-AzConnectedKubernetes { # A lot of what follows relies on knowing the cloud we are using and the # various endpoints so get that information now. - $cloudMetadata = Get-AzCloudMetadata + $cloudMetadata = Get-AzCloudMetadata ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) # Perform DP health check - $configDpinfo = Get-ConfigDPEndpoint -location $Location -Cloud $cloudMetadata + $configDpinfo = Get-ConfigDPEndpoint ` + -location $Location ` + -Cloud $cloudMetadata ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) + $configDPEndpoint = $configDpInfo.configDPEndpoint # If the health check fails (not 200 response), an exception is thrown # so we can ignore the output. - $null = Invoke-ConfigDPHealthCheck -configDPEndpoint $configDPEndpoint + $null = Invoke-ConfigDPHealthCheck ` + -configDPEndpoint $configDPEndpoint ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) # This call does the "pure ARM" update of the ARM objects. Write-Debug "Updating Connected Kubernetes ARM objects." @@ -642,7 +655,12 @@ function Set-AzConnectedKubernetes { # Config DP annd this Powershell script if a new Kubernetes # feature is added. # Do not send protected settings to CCRP - $arcAgentryConfigs = ConvertTo-ArcAgentryConfiguration -ConfigurationSetting $ConfigurationSetting -RedactedProtectedConfiguration @{} -CCRP $true + $arcAgentryConfigs = ConvertTo-ArcAgentryConfiguration ` + -ConfigurationSetting $ConfigurationSetting ` + -RedactedProtectedConfiguration @{} ` + -CCRP $true ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) # It is possible to set an empty value for these parameters and then # the code above gets skipped but we still need to remove the empty @@ -656,7 +674,8 @@ function Set-AzConnectedKubernetes { if ($userProvidedArcConfiguration) { $PSBoundParameters.Add('ArcAgentryConfiguration', $arcAgentryConfigs) - } else { + } + else { $PSBoundParameters.Add('ArcAgentryConfiguration', $ExistConnectedKubernetes.ArcAgentryConfiguration) } @@ -666,7 +685,13 @@ function Set-AzConnectedKubernetes { Write-Error "Failed to update the 'Kubernetes - Azure Arc' resource" return } - $arcAgentryConfigs = ConvertTo-ArcAgentryConfiguration -ConfigurationSetting $ConfigurationSetting -RedactedProtectedConfiguration $RedactedProtectedConfiguration -CCRP $false + $arcAgentryConfigs = ConvertTo-ArcAgentryConfiguration ` + -ConfigurationSetting $ConfigurationSetting ` + -RedactedProtectedConfiguration $RedactedProtectedConfiguration ` + -CCRP $false ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) + # Convert the $Response object into a nested hashtable. Write-Debug "PUT response: $Response" @@ -682,7 +707,8 @@ function Set-AzConnectedKubernetes { if ($userProvidedArcConfiguration) { $Response['properties']['arcAgentryConfigurations'] = $arcAgentryConfigs - } else { + } + else { $Response['properties']['arcAgentryConfigurations'] = $ExistConnectedKubernetes.ArcAgentryConfiguration } @@ -713,7 +739,7 @@ function Set-AzConnectedKubernetes { $optionsFromDp = "" foreach ($field in $helmValuesContent.PSObject.Properties) { - if($field.Value.StartsWith($ProtectedSettingsPlaceholderValue)){ + if ($field.Value.StartsWith($ProtectedSettingsPlaceholderValue)) { $parsedValue = $field.Value.Split(":") # "${ProtectedSettingsPlaceholderValue}:${feature}:${setting}" $field.Value = $ConfigurationProtectedSetting[$parsedValue[1]][$parsedValue[2]] @@ -734,9 +760,15 @@ function Set-AzConnectedKubernetes { if ($PSCmdlet.ShouldProcess('configDP', 'get helm chart path')) { # Get helm chart path (within the OCI registry). - $chartPath = Get-HelmChartPath -registryPath $registryPath -kubeConfig $KubeConfig -kubeContext $KubeContext -helmClientLocation $HelmClientLocation + $chartPath = Get-HelmChartPath ` + -registryPath $registryPath ` + -kubeConfig $KubeConfig ` + -kubeContext $KubeContext ` + -helmClientLocation $HelmClientLocation ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) if (Test-Path Env:HELMCHART) { - $ChartPath = Get-ChildItem -Path Env:HELMCHART + $ChartPath = Get-ChildItem -Path $Env:HELMCHART } } @@ -792,9 +824,11 @@ function Set-AzConnectedKubernetes { if ($ExistConnectedKubernetes.ArcAgentProfileAgentState -eq "Succeeded") { Write-Output "Cluster configuration succeeded." - } elseif ($ExistConnectedKubernetes.ArcAgentProfileAgentState -eq "Failed") { + } + elseif ($ExistConnectedKubernetes.ArcAgentProfileAgentState -eq "Failed") { Write-Error "Cluster configuration failed." - } else { + } + else { Write-Error "Cluster configuration timed out after 60 minutes." } } diff --git a/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/helpers/AzCloudMetadataHelper.ps1 b/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/helpers/AzCloudMetadataHelper.ps1 index 6bf3a4c1fd28..37782d6cbb39 100644 --- a/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/helpers/AzCloudMetadataHelper.ps1 +++ b/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/helpers/AzCloudMetadataHelper.ps1 @@ -27,10 +27,11 @@ Function Get-AzCloudMetadata { throw "Failed to get the current Azure context. Error: $_" } $cloudName = $context.Environment.Name + Write-Debug -Message "cloudName: $cloudName." try { # $Response = Invoke-RestMethod -Uri $MetadataEndpoint -Method Get -StatusCodeVariable StatusCode - $cloud = Get-AzureEnvironment -Name $cloudName + $cloud = Get-AzEnvironment -Name $cloudName } catch { Write-Error "Failed to request ARM metadata. Error: $_" diff --git a/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/helpers/ConfigDPHelper.ps1 b/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/helpers/ConfigDPHelper.ps1 index 290932d25b7c..10bdb8d79079 100644 --- a/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/helpers/ConfigDPHelper.ps1 +++ b/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/helpers/ConfigDPHelper.ps1 @@ -22,7 +22,17 @@ function Invoke-ConfigDPHealthCheck { } # Sending request with retries - Invoke-RestMethodWithUriParameters -Method 'post' -Uri $chartLocationUrl -Headers $headers -UriParameters $uriParameters -MaximumRetryCount 5 -RetryIntervalSec 3 -StatusCodeVariable statusCode + Invoke-RestMethodWithUriParameters ` + -Method 'post' ` + -Uri $chartLocationUrl ` + -Headers $headers ` + -UriParameters $uriParameters ` + -MaximumRetryCount 5 ` + -RetryIntervalSec 3 ` + -StatusCodeVariable statusCode ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) + if ($statusCode -ne 200) { throw "Error while performing DP health check, StatusCode: ${statusCode}" } @@ -41,7 +51,11 @@ function Get-ConfigDPEndpoint { $ReleaseTrain = $null # Get the default config dataplane endpoint. Note that there may be code - $ConfigDpEndpoint = Get-ConfigDpDefaultEndpoint -Location $Location -CloudMetadata $cloudMetadata + $ConfigDpEndpoint = Get-ConfigDpDefaultEndpoint ` + -Location $Location ` + -CloudMetadata $cloudMetadata ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) return @{ ConfigDpEndpoint = $ConfigDpEndpoint; ReleaseTrain = $ReleaseTrain } } diff --git a/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/helpers/HelmHelper.ps1 b/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/helpers/HelmHelper.ps1 index d3f17220db32..5f0d57f57eb7 100644 --- a/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/helpers/HelmHelper.ps1 +++ b/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/helpers/HelmHelper.ps1 @@ -7,7 +7,10 @@ function Set-HelmClientLocation { ) process { Write-Debug "Setting Helm client location." - $HelmLocation = Get-HelmClientLocation + $HelmLocation = Get-HelmClientLocation ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) + if ($null -eq $HelmLocation) { Write-Debug "Helm location not found." return @@ -138,20 +141,38 @@ function Get-HelmChartPath { # Special path! $PreOnboardingHelmChartsFolderName = 'PreOnboardingChecksCharts' - # Exporting Helm chart + # Exporting Helm chart; note that we might be one Windows or Linux. + if (Test-Path Env:USERPROFILE) { + $root = $Env:USERPROFILE + } + elseif (Test-Path Env:HOME) { + $root = $Env:HOME + } + else { + throw "No environment to use as root." + } Write-Verbose "Using 'helm' to add Azure Arc resources to Kubernetes cluster" - $ChartExportPath = Join-Path $env:USERPROFILE ('.azure', $ChartFolderName -join '\') + $ChartExportPath = Join-Path -Path $root -ChildPath '.azure' -AdditionalChildPath $ChartFolderName try { if (Test-Path $ChartExportPath) { Write-Debug "Cleaning up existing Helm chart folder at: $ChartExportPath" - Remove-Item $ChartExportPath -Recurse -Force + Remove-Item -Path $ChartExportPath -Recurse -Force } } catch { Write-Warning -Message "Unable to cleanup the $ChartFolderName already present on the machine. In case of failure, please cleanup the directory '$ChartExportPath' and try again." } Write-Debug "Starting Helm chart export to path: $ChartExportPath" - Get-HelmChart -RegistryPath $RegistryPath -ChartExportPath $ChartExportPath -KubeConfig $KubeConfig -KubeContext $KubeContext -HelmClientLocation $HelmClientLocation -NewPath $NewPath -ChartName $ChartName + Get-HelmChart ` + -RegistryPath $RegistryPath ` + -ChartExportPath $ChartExportPath ` + -KubeConfig $KubeConfig ` + -KubeContext $KubeContext ` + -HelmClientLocation $HelmClientLocation ` + -NewPath $NewPath ` + -ChartName $ChartName ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) # Returning helm chart path $HelmChartPath = Join-Path $ChartExportPath $ChartName @@ -250,8 +271,8 @@ function Set-HelmRepositoryAndModules { ) Write-Debug "Setting Helm repository and checking for required modules." if ((Test-Path Env:HELMREPONAME) -and (Test-Path Env:HELMREPOURL)) { - $HelmRepoName = Get-ChildItem -Path Env:HELMREPONAME - $HelmRepoUrl = Get-ChildItem -Path Env:HELMREPOURL + $HelmRepoName = (Get-Item Env:HELMREPONAME).Value + $HelmRepoUrl = (Get-Item Env:HELMREPOURL).Value helm repo add $HelmRepoName $HelmRepoUrl --kubeconfig $KubeConfig --kube-context $KubeContext } @@ -262,12 +283,12 @@ function Set-HelmRepositoryAndModules { } if (Test-Path Env:HELMREGISTRY) { - $RegistryPath = Get-ChildItem -Path Env:HELMREGISTRY + $RegistryPath = (Get-Item Env:HELMREGISTRY).Value } else { $ReleaseTrain = '' if ((Test-Path Env:RELEASETRAIN) -and (Test-Path Env:RELEASETRAIN)) { - $ReleaseTrain = Get-ChildItem -Path Env:RELEASETRAIN + $ReleaseTrain = (Get-Item Env:RELEASETRAIN).Value } else { $ReleaseTrain = 'stable' @@ -314,7 +335,10 @@ function Get-HelmReleaseNamespaces { [string]$KubeContext ) Write-Debug "Getting release namespace." - $ReleaseInstallNamespace = Get-ReleaseInstallNamespace + $ReleaseInstallNamespace = Get-ReleaseInstallNamespace ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) + $ReleaseNamespace = $null try { $ReleaseNamespace = (helm status azure-arc -o json --kubeconfig $KubeConfig --kube-context $KubeContext -n $ReleaseInstallNamespace 2> $null | ConvertFrom-Json).namespace @@ -332,7 +356,10 @@ function Confirm-HelmVersion { ) Write-Debug "Setting up Helm client location and validating Helm version." try { - Set-HelmClientLocation + Set-HelmClientLocation ` + -Verbose:($PSCmdlet.MyInvocation.BoundParameters["Verbose"].IsPresent -eq $true) ` + -Debug:($PSCmdlet.MyInvocation.BoundParameters["Debug"].IsPresent -eq $true) + $HelmVersion = helm version --template='{{.Version}}' --kubeconfig $KubeConfig if ($HelmVersion.Contains("v2")) { Write-Error "Helm version 3+ is required (not ${HelmVersion}). Learn more at https://aka.ms/arc/k8s/onboarding-helm-install" diff --git a/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/helpers/UtilsHelper.ps1 b/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/helpers/UtilsHelper.ps1 index 3e6e79598ebd..7b6ced587914 100644 --- a/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/helpers/UtilsHelper.ps1 +++ b/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/custom/helpers/UtilsHelper.ps1 @@ -67,8 +67,8 @@ function ConvertTo-ArcAgentryConfiguration { else { $protectedSettings = ($RedactedProtectedConfiguration.ContainsKey($feature) ? $RedactedProtectedConfiguration[$feature] : @{}) $ArcAgentryConfiguration = @{ - Feature = $feature - Settings = $settings + Feature = $feature + Settings = $settings ProtectedSettings = $protectedSettings } } diff --git a/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/test/New-AzConnectedKubernetes.Tests.ps1 b/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/test/New-AzConnectedKubernetes.Tests.ps1 index 401bfa460dd1..76c3449bff21 100644 --- a/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/test/New-AzConnectedKubernetes.Tests.ps1 +++ b/src/ConnectedKubernetes/ConnectedKubernetes.Autorest/test/New-AzConnectedKubernetes.Tests.ps1 @@ -174,7 +174,7 @@ Describe 'Get-AzCloudMetadata' { # For some reason Pester fails to "see" Get-AzureEnvirnomment so we create # and empty instance here that we can the mock. BeforeEach { - Function Get-AzureEnvironment { + Function Get-AzEnvironment { } } @@ -186,7 +186,7 @@ Describe 'Get-AzCloudMetadata' { } } } - Mock Get-AzureEnvironment { + Mock Get-AzEnvironment { $context = [PSCustomObject]@{ Name = "AzureCloud" } @@ -194,9 +194,9 @@ Describe 'Get-AzCloudMetadata' { } { $Script:cloud = Get-AzCloudMetadata } | Should -Not -Throw Assert-MockCalled "Get-AzContext" -Times 1 - Assert-MockCalled "Get-AzureEnvironment" -Times 1 + Assert-MockCalled "Get-AzEnvironment" -Times 1 # Ref: https://github.com/pester/Pester/issues/2556 - # Assert-MockCalled "Get-AzureEnvironment" -Times 1 -ParameterFilter { $Local:Name -eq "SovereignAzureCloud" } + # Assert-MockCalled "Get-AzEnvironment" -Times 1 -ParameterFilter { $Local:Name -eq "SovereignAzureCloud" } Assert-VerifiableMock $cloud.name | Should -Be "AzureCloud" } @@ -210,7 +210,7 @@ Describe 'Get-AzCloudMetadata' { Assert-VerifiableMock } - It 'Get-AzureEnvironment fails' { + It 'Get-AzEnvironment fails' { Mock Get-AzContext { return [PSCustomObject]@{ Environment = [PSCustomObject]@{ @@ -218,7 +218,7 @@ Describe 'Get-AzCloudMetadata' { } } } - Mock Get-AzureEnvironment { + Mock Get-AzEnvironment { throw "Some error!" } { Get-AzCloudMetadata } | Should -Throw "Failed to request ARM metadata. Error: Some error!" diff --git a/src/ConnectedKubernetes/ConnectedKubernetes/Az.ConnectedKubernetes.psd1 b/src/ConnectedKubernetes/ConnectedKubernetes/Az.ConnectedKubernetes.psd1 index 64ae68d435ed..6e5e2c6dfe99 100644 --- a/src/ConnectedKubernetes/ConnectedKubernetes/Az.ConnectedKubernetes.psd1 +++ b/src/ConnectedKubernetes/ConnectedKubernetes/Az.ConnectedKubernetes.psd1 @@ -3,7 +3,7 @@ # # Generated by: Microsoft Corporation # -# Generated on: 9/25/2024 +# Generated on: 10/11/2024 # @{ @@ -58,10 +58,10 @@ RequiredAssemblies = 'ConnectedKubernetes.Autorest/bin/Az.ConnectedKubernetes.private.dll' # Script files (.ps1) that are run in the caller's environment prior to importing this module. -# ScriptsToProcess = @() +ScriptsToProcess = @() # Type files (.ps1xml) to be loaded when importing this module -# TypesToProcess = @() +TypesToProcess = @() # Format files (.ps1xml) to be loaded when importing this module FormatsToProcess = @@ -100,7 +100,7 @@ PrivateData = @{ PSData = @{ # Tags applied to this module. These help with module discovery in online galleries. - Tags = 'Azure','ResourceManager','ARM','PSModule','ConnectedKubernetes' + Tags = 'Azure', 'ResourceManager', 'ARM', 'PSModule', 'ConnectedKubernetes' # A URL to the license for this module. LicenseUri = 'https://aka.ms/azps-license' @@ -127,7 +127,7 @@ PrivateData = @{ } # End of PSData hashtable - } # End of PrivateData hashtable +} # End of PrivateData hashtable # HelpInfo URI of this module # HelpInfoURI = '' diff --git a/src/ConnectedKubernetes/ConnectedKubernetes/ChangeLog.md b/src/ConnectedKubernetes/ConnectedKubernetes/ChangeLog.md index ac9421fefa58..d2ff4bf5bcc6 100644 --- a/src/ConnectedKubernetes/ConnectedKubernetes/ChangeLog.md +++ b/src/ConnectedKubernetes/ConnectedKubernetes/ChangeLog.md @@ -18,6 +18,8 @@ - Additional information about change #1 --> ## Upcoming Release +* Fixed environment variable usage +* Got rid of deprecated module and improved logging ## Version 0.11.0 * Added support for Workload Identity Federation and OIDC Issuer features to the ConnectedKubernetes cmdlets. diff --git a/src/ConnectedKubernetes/ConnectedKubernetes/help/Get-AzConnectedKubernetes.md b/src/ConnectedKubernetes/ConnectedKubernetes/help/Get-AzConnectedKubernetes.md index e71eac216058..ede97042bea7 100644 --- a/src/ConnectedKubernetes/ConnectedKubernetes/help/Get-AzConnectedKubernetes.md +++ b/src/ConnectedKubernetes/ConnectedKubernetes/help/Get-AzConnectedKubernetes.md @@ -15,25 +15,25 @@ Returns the properties of the specified connected cluster, including name, ident ### List1 (Default) ``` Get-AzConnectedKubernetes [-SubscriptionId ] [-DefaultProfile ] - [] + [-ProgressAction ] [] ``` ### Get ``` Get-AzConnectedKubernetes -ClusterName -ResourceGroupName [-SubscriptionId ] - [-DefaultProfile ] [] + [-DefaultProfile ] [-ProgressAction ] [] ``` ### List ``` Get-AzConnectedKubernetes -ResourceGroupName [-SubscriptionId ] [-DefaultProfile ] - [] + [-ProgressAction ] [] ``` ### GetViaIdentity ``` Get-AzConnectedKubernetes -InputObject [-DefaultProfile ] - [] + [-ProgressAction ] [] ``` ## DESCRIPTION @@ -145,6 +145,21 @@ Accept pipeline input: True (ByValue) Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/ConnectedKubernetes/ConnectedKubernetes/help/Get-AzConnectedKubernetesUserCredential.md b/src/ConnectedKubernetes/ConnectedKubernetes/help/Get-AzConnectedKubernetesUserCredential.md index 29236a32fb92..a637be44a2d9 100644 --- a/src/ConnectedKubernetes/ConnectedKubernetes/help/Get-AzConnectedKubernetesUserCredential.md +++ b/src/ConnectedKubernetes/ConnectedKubernetes/help/Get-AzConnectedKubernetesUserCredential.md @@ -16,14 +16,14 @@ Gets cluster user credentials of the connected cluster with a specified resource ``` Get-AzConnectedKubernetesUserCredential -ClusterName -ResourceGroupName [-SubscriptionId ] -AuthenticationMethod [-ClientProxy] - [-DefaultProfile ] [-WhatIf] [-Confirm] [] + [-DefaultProfile ] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### List ``` Get-AzConnectedKubernetesUserCredential -ClusterName -ResourceGroupName [-SubscriptionId ] -Property [-DefaultProfile ] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -130,6 +130,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -Property . To construct, see NOTES section for PROPERTY properties and create a hash table. diff --git a/src/ConnectedKubernetes/ConnectedKubernetes/help/New-AzConnectedKubernetes.md b/src/ConnectedKubernetes/ConnectedKubernetes/help/New-AzConnectedKubernetes.md index 8b20dcb33233..089741860d62 100644 --- a/src/ConnectedKubernetes/ConnectedKubernetes/help/New-AzConnectedKubernetes.md +++ b/src/ConnectedKubernetes/ConnectedKubernetes/help/New-AzConnectedKubernetes.md @@ -22,7 +22,7 @@ New-AzConnectedKubernetes -ClusterName -ResourceGroupName [-Su [-CustomLocationsOid ] [-OidcIssuerProfileEnabled] [-OidcIssuerProfileSelfHostedIssuerUrl ] [-WorkloadIdentityEnabled] [-AcceptEULA] [-DefaultProfile ] [-AsJob] [-NoWait] [-ConfigurationSetting ] [-ConfigurationProtectedSetting ] [-GatewayResourceId ] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -531,6 +531,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ProvisioningState Provisioning state of the connected cluster resource. diff --git a/src/ConnectedKubernetes/ConnectedKubernetes/help/Remove-AzConnectedKubernetes.md b/src/ConnectedKubernetes/ConnectedKubernetes/help/Remove-AzConnectedKubernetes.md index 53da0f8dffd1..58ef17e2141a 100644 --- a/src/ConnectedKubernetes/ConnectedKubernetes/help/Remove-AzConnectedKubernetes.md +++ b/src/ConnectedKubernetes/ConnectedKubernetes/help/Remove-AzConnectedKubernetes.md @@ -16,14 +16,14 @@ Delete a connected cluster, removing the tracked resource in Azure Resource Mana ``` Remove-AzConnectedKubernetes -ClusterName -ResourceGroupName [-SubscriptionId ] [-KubeConfig ] [-KubeContext ] [-DefaultProfile ] [-AsJob] [-NoWait] [-PassThru] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### DeleteViaIdentity ``` Remove-AzConnectedKubernetes -InputObject [-KubeConfig ] [-KubeContext ] [-DefaultProfile ] [-AsJob] [-NoWait] [-PassThru] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -168,6 +168,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/ConnectedKubernetes/ConnectedKubernetes/help/Set-AzConnectedKubernetes.md b/src/ConnectedKubernetes/ConnectedKubernetes/help/Set-AzConnectedKubernetes.md index 51761d0e98c7..9b38d47ecf54 100644 --- a/src/ConnectedKubernetes/ConnectedKubernetes/help/Set-AzConnectedKubernetes.md +++ b/src/ConnectedKubernetes/ConnectedKubernetes/help/Set-AzConnectedKubernetes.md @@ -23,7 +23,7 @@ Set-AzConnectedKubernetes -ClusterName -ResourceGroupName [-Su [-OidcIssuerProfileEnabled] [-OidcIssuerProfileSelfHostedIssuerUrl ] [-WorkloadIdentityEnabled] [-AcceptEULA] [-ConfigurationSetting ] [-ConfigurationProtectedSetting ] [-GatewayResourceId ] [-DefaultProfile ] [-AsJob] [-NoWait] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### SetExpandedDisableGateway @@ -37,7 +37,7 @@ Set-AzConnectedKubernetes -ClusterName -ResourceGroupName [-Su [-OidcIssuerProfileEnabled] [-OidcIssuerProfileSelfHostedIssuerUrl ] [-WorkloadIdentityEnabled] [-AcceptEULA] [-ConfigurationSetting ] [-ConfigurationProtectedSetting ] [-GatewayResourceId ] [-DisableGateway] [-DefaultProfile ] [-AsJob] [-NoWait] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### SetDisableGateway @@ -51,7 +51,7 @@ Set-AzConnectedKubernetes [-SubscriptionId ] [-HttpProxy ] [-HttpsP [-WorkloadIdentityEnabled] [-AcceptEULA] [-ConfigurationSetting ] [-ConfigurationProtectedSetting ] [-GatewayResourceId ] [-DisableGateway] -InputObject [-DefaultProfile ] [-AsJob] [-NoWait] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### Set @@ -64,7 +64,7 @@ Set-AzConnectedKubernetes [-SubscriptionId ] [-HttpProxy ] [-HttpsP [-CustomLocationsOid ] [-OidcIssuerProfileEnabled] [-OidcIssuerProfileSelfHostedIssuerUrl ] [-WorkloadIdentityEnabled] [-AcceptEULA] [-ConfigurationSetting ] [-ConfigurationProtectedSetting ] [-GatewayResourceId ] -InputObject - [-DefaultProfile ] [-AsJob] [-NoWait] [-WhatIf] [-Confirm] + [-DefaultProfile ] [-AsJob] [-NoWait] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` @@ -505,6 +505,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ProvisioningState Provisioning state of the connected cluster resource. diff --git a/src/ConnectedKubernetes/ConnectedKubernetes/help/Update-AzConnectedKubernetes.md b/src/ConnectedKubernetes/ConnectedKubernetes/help/Update-AzConnectedKubernetes.md index 4ee40c351d11..8bb7e117f9db 100644 --- a/src/ConnectedKubernetes/ConnectedKubernetes/help/Update-AzConnectedKubernetes.md +++ b/src/ConnectedKubernetes/ConnectedKubernetes/help/Update-AzConnectedKubernetes.md @@ -17,7 +17,7 @@ API to update certain properties of the connected cluster resource Update-AzConnectedKubernetes -ClusterName -ResourceGroupName [-SubscriptionId ] [-AzureHybridBenefit ] [-AcceptEULA] [-Distribution ] [-DistributionVersion ] [-Tag ] [-DefaultProfile ] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### UpdateViaIdentityExpanded @@ -25,7 +25,7 @@ Update-AzConnectedKubernetes -ClusterName -ResourceGroupName [ Update-AzConnectedKubernetes -InputObject [-AzureHybridBenefit ] [-AcceptEULA] [-Distribution ] [-DistributionVersion ] [-Tag ] [-DefaultProfile ] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -196,6 +196,21 @@ Accept pipeline input: True (ByValue) Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI.Autorest/custom/stackhci.ps1 b/src/StackHCI/StackHCI.Autorest/custom/stackhci.ps1 index 7d302dcb9c2c..4524e1c682c7 100644 --- a/src/StackHCI/StackHCI.Autorest/custom/stackhci.ps1 +++ b/src/StackHCI/StackHCI.Autorest/custom/stackhci.ps1 @@ -151,12 +151,16 @@ $AzureGermanCloudPortalDomain = "https://portal.microsoftazure.de/" $AzurePPEPortalDomain = "https://df.onecloud.azure-test.net/" $AzureCanaryPortalDomain = "https://portal.azure.com/" +$DOMAINFQDNMACRO = "{DomainFqdn}" +$AzureLocalPortalDomain = "https://portal.$DOMAINFQDNMACRO" + $AzureCloud = "AzureCloud" $AzureChinaCloud = "AzureChinaCloud" $AzureUSGovernment = "AzureUSGovernment" $AzureGermanCloud = "AzureGermanCloud" $AzurePPE = "AzurePPE" $AzureCanary = "AzureCanary" +$AzureLocal = "Azure.local" $PortalCanarySuffix = '?feature.armendpointprefix={0}' $PortalHCIResourceUrl = '#@{0}/resource/subscriptions/{1}/resourceGroups/{2}/providers/Microsoft.AzureStackHCI/clusters/{3}/overview' @@ -196,6 +200,11 @@ $AuthorityAzureGermanCloud = "https://login.microsoftonline.de" $BillingServiceApiScopeAzureGermanCloud = "https://azurestackhci-usage.azurewebsites.de/.default" $GraphServiceApiScopeAzureGermanCloud = "https://graph.cloudapi.de/.default" +$ServiceEndpointAzureLocal = "https://dp.aszrp.$DOMAINFQDNMACRO" +$AuthorityAzureLocal = "https://login.$DOMAINFQDNMACRO" +$BillingServiceApiScopeAzureLocal = "https://dp.aszrp.$DOMAINFQDNMACRO/.default" +$GraphServiceApiScopeAzureLocal = "https://graph.$DOMAINFQDNMACRO" + $RPAPIVersion = "2022-12-01"; $HCIArcAPIVersion = "2023-03-01" $HCIArcExtensionAPIVersion = "2021-09-01" @@ -1029,6 +1038,10 @@ param( $PortalCanarySuffixWithRegion = $PortalCanarySuffix -f $Region return ($AzureCanaryPortalDomain + $PortalCanarySuffixWithRegion); } + elseif($EnvironmentName -eq $AzureLocal) + { + return $AzureLocalPortalDomain; + } } function Get-DefaultRegion{ @@ -1063,6 +1076,10 @@ param( { $defaultRegion = "eastus2euap" } + elseif($EnvironmentName -eq $AzureLocal) + { + $defaultRegion = "autonomous" + } return $defaultRegion } @@ -1130,6 +1147,13 @@ param( $BillingServiceApiScope.Value = $BillingServiceApiScopeAzurePPE $GraphServiceApiScope.Value = $GraphServiceApiScopeAzurePPE } + elseif($EnvironmentName -eq $AzureLocal) + { + $ServiceEndpoint.Value = $ServiceEndpointAzureLocal + $Authority.Value = $AuthorityAzureLocal + $BillingServiceApiScope.Value = $BillingServiceApiScopeAzureLocal + $GraphServiceApiScope.Value = $GraphServiceApiScopeAzureLocal + } } @@ -1409,6 +1433,39 @@ param( return $regionName } +function Initialize-AzureLocalConfig { + $endpoints = Retry-Command -ScriptBlock { (Invoke-WebRequest -Uri "http://localhost:40342/metadata/endpoints?api-version=2020-06-01" -Headers @{"metadata"="true"; "UseDefaultCredentials"="true" } -UseBasicParsing).Content | ConvertFrom-Json} + + # Extract domain FQDN from storage suffix. + $domainFQDN=$endpoints.Suffixes.Storage + + # Update default configurations based on the domain FQDN. + $script:AzureLocalPortalDomain = $script:AzureLocalPortalDomain.Replace($DOMAINFQDNMACRO, $domainFQDN) + $script:ServiceEndpointAzureLocal = $script:ServiceEndpointAzureLocal.Replace($DOMAINFQDNMACRO, $domainFQDN) + $script:AuthorityAzureLocal = $script:AuthorityAzureLocal.Replace($DOMAINFQDNMACRO, $domainFQDN) + $script:BillingServiceApiScopeAzureLocal = $script:BillingServiceApiScopeAzureLocal.Replace($DOMAINFQDNMACRO, $domainFQDN) + $script:GraphServiceApiScopeAzureLocal = $script:GraphServiceApiScopeAzureLocal.Replace($DOMAINFQDNMACRO, $domainFQDN) + + Write-VerboseLog "Default Azure Local configurations - Portal: $AzureLocalPortalDomain, ServiceEndpoint: $ServiceEndpointAzureLocal, Authority: $AuthorityAzureLocal, BillingServiceApiScope: $BillingServiceApiScopeAzureLocal, GraphServiceApiScope: $GraphServiceApiScopeAzureLocal" + + # Over write the default configurations if the endpoint is available as part of the metadata. + if ($endpoints.portal) { + $script:AzureLocalPortal = $endpoints.portal + } + if ($endpoints.dataplaneEndpoints.hciDataplaneServiceEndpoint) { + $script:ServiceEndpointAzureLocal = $endpoints.dataplaneEndpoints.hciDataplaneServiceEndpoint + $script:BillingServiceApiScopeAzureLocal = "$($endpoints.dataplaneEndpoints.hciDataplaneServiceEndpoint)/.default" + } + if ($endpoints.authentication.loginEndpoint) { + $script:AuthorityAzureLocal = $endpoints.authentication.loginEndpoint + } + if ($endpoints.graph) { + $script:GraphServiceApiScopeAzureLocal = $endpoints.graph + } + + Write-VerboseLog "Azure Local configurations after override - Portal: $AzureLocalPortalDomain, ServiceEndpoint: $ServiceEndpointAzureLocal, Authority: $AuthorityAzureLocal, BillingServiceApiScope: $BillingServiceApiScopeAzureLocal, GraphServiceApiScope: $GraphServiceApiScopeAzureLocal" +} + function Validate-RegionName{ [Microsoft.Azure.PowerShell.Cmdlets.StackHCI.DoNotExportAttribute()] param( @@ -2895,6 +2952,12 @@ param( Write-VerboseLog ("Cloud Management Infra supported: {0}" -f $isCloudManagementInfraSupported) Write-VerboseLog ("Installing Mandatory extensions supported: {0}" -f $isDefaultExtensionSupported) + if ($EnvironmentName -eq $AzureLocal) + { + Write-VerboseLog ("Registering in Azure Local. Initiliazing Azure.local configurations") + Initialize-AzureLocalConfig + } + if(-Not ([string]::IsNullOrEmpty($RegContext.AzureResourceUri))) { if([string]::IsNullOrEmpty($ResourceName)) @@ -4181,31 +4244,34 @@ param( $TenantId = Azure-Login -SubscriptionId $SubscriptionId -TenantId $TenantId -ArmAccessToken $ArmAccessToken -GraphAccessToken $GraphAccessToken -AccountId $AccountId -EnvironmentName $EnvironmentName -ProgressActivityName $UnregisterProgressActivityName -UseDeviceAuthentication $UseDeviceAuthentication -Region $Region Write-Progress -Id $MainProgressBarId -activity $UnregisterProgressActivityName -status $UnregisterArcMessage -percentcomplete 40 - - $arcUnregisterRes = Unregister-ArcForServers -IsManagementNode $IsManagementNode -ComputerName $ComputerName -Credential $Credential -ResourceId $resourceId -Force:$Force -ClusterDNSSuffix $clusterDNSSuffix - - if($arcUnregisterRes -eq $false) - { - $resultValue = [OperationStatus]::Failed - $unregisterArcForServersWacErrorCode = 9117 - $unregistrationOutput | Add-Member -MemberType NoteProperty -Name $OutputPropertyResult -Value $resultValue - Set-WacOutputProperty -IsWAC $IsWAC -PropertyName $OutputPropertyWacResult -PropertyValue $resultValue.ToString() -Output $unregistrationOutput - Set-WacOutputProperty -IsWAC $IsWAC -PropertyName $OutputPropertyWacErrorCode -PropertyValue $unregisterArcForServersWacErrorCode -Output $unregistrationOutput - Write-Output $unregistrationOutput | Format-List - Write-NodeEventLog -Message "ARC unregistration failed" -EventID 9117 -IsManagementNode $IsManagementNode -credentials $Credential -ComputerName $ComputerName -Level Warning - return - } - else + + if ($EnvironmentName -ne $AzureLocal) { - if ($DisableOnlyAzureArcServer -eq $true) + $arcUnregisterRes = Unregister-ArcForServers -IsManagementNode $IsManagementNode -ComputerName $ComputerName -Credential $Credential -ResourceId $resourceId -Force:$Force -ClusterDNSSuffix $clusterDNSSuffix + + if($arcUnregisterRes -eq $false) { - $resultValue = [OperationStatus]::Success + $resultValue = [OperationStatus]::Failed + $unregisterArcForServersWacErrorCode = 9117 $unregistrationOutput | Add-Member -MemberType NoteProperty -Name $OutputPropertyResult -Value $resultValue Set-WacOutputProperty -IsWAC $IsWAC -PropertyName $OutputPropertyWacResult -PropertyValue $resultValue.ToString() -Output $unregistrationOutput + Set-WacOutputProperty -IsWAC $IsWAC -PropertyName $OutputPropertyWacErrorCode -PropertyValue $unregisterArcForServersWacErrorCode -Output $unregistrationOutput Write-Output $unregistrationOutput | Format-List - Write-NodeEventLog -Message "Disabling only ARC for Servers. UnRegistration completed successfully" -EventID 9008 -IsManagementNode $IsManagementNode -credentials $Credential -ComputerName $ComputerName + Write-NodeEventLog -Message "ARC unregistration failed" -EventID 9117 -IsManagementNode $IsManagementNode -credentials $Credential -ComputerName $ComputerName -Level Warning return } + else + { + if ($DisableOnlyAzureArcServer -eq $true) + { + $resultValue = [OperationStatus]::Success + $unregistrationOutput | Add-Member -MemberType NoteProperty -Name $OutputPropertyResult -Value $resultValue + Set-WacOutputProperty -IsWAC $IsWAC -PropertyName $OutputPropertyWacResult -PropertyValue $resultValue.ToString() -Output $unregistrationOutput + Write-Output $unregistrationOutput | Format-List + Write-NodeEventLog -Message "Disabling only ARC for Servers. UnRegistration completed successfully" -EventID 9008 -IsManagementNode $IsManagementNode -credentials $Credential -ComputerName $ComputerName + return + } + } } Write-Progress -Id $MainProgressBarId -activity $UnregisterProgressActivityName -status $UnregisterHCIUsageMessage -percentcomplete 45 diff --git a/src/StackHCI/StackHCI/Az.StackHCI.psd1 b/src/StackHCI/StackHCI/Az.StackHCI.psd1 index a6a7c0d8e282..3d28b182c1ff 100644 --- a/src/StackHCI/StackHCI/Az.StackHCI.psd1 +++ b/src/StackHCI/StackHCI/Az.StackHCI.psd1 @@ -3,7 +3,7 @@ # # Generated by: Microsoft Corporation # -# Generated on: 7/31/2024 +# Generated on: 10/10/2024 # @{ @@ -51,16 +51,16 @@ DotNetFrameworkVersion = '4.7.2' # ProcessorArchitecture = '' # Modules that must be imported into the global environment prior to importing this module -RequiredModules = @(@{ModuleName = 'Az.Accounts'; ModuleVersion = '3.0.3'; }) +RequiredModules = @(@{ModuleName = 'Az.Accounts'; ModuleVersion = '3.0.4'; }) # Assemblies that must be loaded prior to importing this module RequiredAssemblies = 'StackHCI.Autorest/bin/Az.StackHCI.private.dll' # Script files (.ps1) that are run in the caller's environment prior to importing this module. -# ScriptsToProcess = @() +ScriptsToProcess = @() # Type files (.ps1xml) to be loaded when importing this module -# TypesToProcess = @() +TypesToProcess = @() # Format files (.ps1xml) to be loaded when importing this module FormatsToProcess = 'StackHCI.Autorest/Az.StackHCI.format.ps1xml' @@ -121,7 +121,7 @@ PrivateData = @{ PSData = @{ # Tags applied to this module. These help with module discovery in online galleries. - Tags = 'Azure','ResourceManager','ARM','PSModule','StackHci' + Tags = 'Azure', 'ResourceManager', 'ARM', 'PSModule', 'StackHci' # A URL to the license for this module. LicenseUri = 'https://aka.ms/azps-license' @@ -147,7 +147,7 @@ PrivateData = @{ } # End of PSData hashtable - } # End of PrivateData hashtable +} # End of PrivateData hashtable # HelpInfo URI of this module # HelpInfoURI = '' diff --git a/src/StackHCI/StackHCI/ChangeLog.md b/src/StackHCI/StackHCI/ChangeLog.md index 40aba0def72a..31dbdcabc78d 100644 --- a/src/StackHCI/StackHCI/ChangeLog.md +++ b/src/StackHCI/StackHCI/ChangeLog.md @@ -18,6 +18,7 @@ - Additional information about change #1 --> ## Upcoming Release +* added support for new environment ## Version 2.4.0 * Upgraded API version to 2024-04-01 diff --git a/src/StackHCI/StackHCI/help/Add-AzStackHCIVMAttestation.md b/src/StackHCI/StackHCI/help/Add-AzStackHCIVMAttestation.md index 84c02b8e54c7..930740d6b67d 100644 --- a/src/StackHCI/StackHCI/help/Add-AzStackHCIVMAttestation.md +++ b/src/StackHCI/StackHCI/help/Add-AzStackHCIVMAttestation.md @@ -14,19 +14,19 @@ Add-AzStackHCIVMAttestation configures guests for AzureStack HCI IMDS Attestatio ### VMName (Default) ``` -Add-AzStackHCIVMAttestation [-VMName] [-Force] [-WhatIf] +Add-AzStackHCIVMAttestation [-VMName] [-Force] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### VMObject ``` -Add-AzStackHCIVMAttestation [-Force] [-VM] [-WhatIf] [-Confirm] +Add-AzStackHCIVMAttestation [-Force] [-VM] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### AddAll ``` -Add-AzStackHCIVMAttestation [-Force] [-AddAll] [-WhatIf] [-Confirm] +Add-AzStackHCIVMAttestation [-Force] [-AddAll] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` @@ -107,6 +107,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -VM Specifies an array of VM objects from Get-VM. diff --git a/src/StackHCI/StackHCI/help/Disable-AzStackHCIAttestation.md b/src/StackHCI/StackHCI/help/Disable-AzStackHCIAttestation.md index 68e526d33b4f..354bc15661f6 100644 --- a/src/StackHCI/StackHCI/help/Disable-AzStackHCIAttestation.md +++ b/src/StackHCI/StackHCI/help/Disable-AzStackHCIAttestation.md @@ -14,7 +14,7 @@ Disable-AzStackHCIAttestation disables IMDS Attestation on the host ``` Disable-AzStackHCIAttestation [[-ComputerName] ] [-Credential ] [-RemoveVM] [-Force] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -83,6 +83,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -RemoveVM Specifies the guests on each node should be removed from IMDS Attestation before disabling on cluster. Disable cannot continue before guests are removed. diff --git a/src/StackHCI/StackHCI/help/Disable-AzStackHCIRemoteSupport.md b/src/StackHCI/StackHCI/help/Disable-AzStackHCIRemoteSupport.md index 6e78cb50b3ad..418f142b0708 100644 --- a/src/StackHCI/StackHCI/help/Disable-AzStackHCIRemoteSupport.md +++ b/src/StackHCI/StackHCI/help/Disable-AzStackHCIRemoteSupport.md @@ -13,7 +13,7 @@ Disables Remote Support. ## SYNTAX ``` -Disable-AzStackHCIRemoteSupport [-WhatIf] [-Confirm] [] +Disable-AzStackHCIRemoteSupport [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -37,6 +37,21 @@ Disabling Remort support ## PARAMETERS +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -Confirm Prompts you for confirmation before running the cmdlet. diff --git a/src/StackHCI/StackHCI/help/Enable-AzStackHCIAttestation.md b/src/StackHCI/StackHCI/help/Enable-AzStackHCIAttestation.md index b243e9029603..5661338ab417 100644 --- a/src/StackHCI/StackHCI/help/Enable-AzStackHCIAttestation.md +++ b/src/StackHCI/StackHCI/help/Enable-AzStackHCIAttestation.md @@ -14,7 +14,7 @@ Enable-AzStackHCIAttestation configures the host and enables specified guests fo ``` Enable-AzStackHCIAttestation [[-ComputerName] ] [-Credential ] [-AddVM] [-Force] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -99,6 +99,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -Confirm Prompts you for confirmation before running the cmdlet. diff --git a/src/StackHCI/StackHCI/help/Enable-AzStackHCIRemoteSupport.md b/src/StackHCI/StackHCI/help/Enable-AzStackHCIRemoteSupport.md index dcfcbe174c6a..8e02d43d2b5e 100644 --- a/src/StackHCI/StackHCI/help/Enable-AzStackHCIRemoteSupport.md +++ b/src/StackHCI/StackHCI/help/Enable-AzStackHCIRemoteSupport.md @@ -14,7 +14,7 @@ Enables Remote Support. ``` Enable-AzStackHCIRemoteSupport [-AccessLevel] [[-ExpireInMinutes] ] [[-SasCredential] ] - [-AgreeToRemoteSupportConsent] [-WhatIf] [-Confirm] [] + [-AgreeToRemoteSupportConsent] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -118,6 +118,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -SasCredential Hybrid Connection SAS Credential. diff --git a/src/StackHCI/StackHCI/help/Get-AzStackHCILogsDirectory.md b/src/StackHCI/StackHCI/help/Get-AzStackHCILogsDirectory.md index 055f8d68ce8f..e76e5801596f 100644 --- a/src/StackHCI/StackHCI/help/Get-AzStackHCILogsDirectory.md +++ b/src/StackHCI/StackHCI/help/Get-AzStackHCILogsDirectory.md @@ -14,7 +14,7 @@ Returns Logs directory path on the current node. ``` Get-AzStackHCILogsDirectory [[-Credential] ] [[-ComputerName] ] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -66,6 +66,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -Confirm Prompts you for confirmation before running the cmdlet. diff --git a/src/StackHCI/StackHCI/help/Get-AzStackHCIRemoteSupportAccess.md b/src/StackHCI/StackHCI/help/Get-AzStackHCIRemoteSupportAccess.md index d98a09608b6a..c4ac60083e75 100644 --- a/src/StackHCI/StackHCI/help/Get-AzStackHCIRemoteSupportAccess.md +++ b/src/StackHCI/StackHCI/help/Get-AzStackHCIRemoteSupportAccess.md @@ -13,7 +13,7 @@ Gets Remote Support Access. ## SYNTAX ``` -Get-AzStackHCIRemoteSupportAccess [-Cluster] [-IncludeExpired] +Get-AzStackHCIRemoteSupportAccess [-Cluster] [-IncludeExpired] [-ProgressAction ] [] ``` @@ -102,6 +102,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### CommonParameters This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). diff --git a/src/StackHCI/StackHCI/help/Get-AzStackHCIRemoteSupportSessionHistory.md b/src/StackHCI/StackHCI/help/Get-AzStackHCIRemoteSupportSessionHistory.md index 225492deb3f1..4fa568ba3af3 100644 --- a/src/StackHCI/StackHCI/help/Get-AzStackHCIRemoteSupportSessionHistory.md +++ b/src/StackHCI/StackHCI/help/Get-AzStackHCIRemoteSupportSessionHistory.md @@ -14,7 +14,7 @@ Gets Remote Support Session History Details. ``` Get-AzStackHCIRemoteSupportSessionHistory [[-SessionId] ] [-IncludeSessionTranscript] - [[-FromDate] ] [] + [[-FromDate] ] [-ProgressAction ] [] ``` ## DESCRIPTION @@ -72,6 +72,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -SessionId Optional. Session Id to get details for a specific session. diff --git a/src/StackHCI/StackHCI/help/Get-AzStackHCIVMAttestation.md b/src/StackHCI/StackHCI/help/Get-AzStackHCIVMAttestation.md index fb65963f86cb..91b7d596d584 100644 --- a/src/StackHCI/StackHCI/help/Get-AzStackHCIVMAttestation.md +++ b/src/StackHCI/StackHCI/help/Get-AzStackHCIVMAttestation.md @@ -13,7 +13,7 @@ Get-AzStackHCIVMAttestation shows a list of guests added to IMDS Attestation on ## SYNTAX ``` -Get-AzStackHCIVMAttestation [-Local] [] +Get-AzStackHCIVMAttestation [-Local] [-ProgressAction ] [] ``` ## DESCRIPTION @@ -76,6 +76,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### CommonParameters This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216). diff --git a/src/StackHCI/StackHCI/help/Get-AzStackHciArcSetting.md b/src/StackHCI/StackHCI/help/Get-AzStackHciArcSetting.md index 707733d6357d..dc805553fca7 100644 --- a/src/StackHCI/StackHCI/help/Get-AzStackHciArcSetting.md +++ b/src/StackHCI/StackHCI/help/Get-AzStackHciArcSetting.md @@ -15,20 +15,20 @@ Get ArcSetting resource details of HCI Cluster. ### List (Default) ``` Get-AzStackHciArcSetting -ClusterName -ResourceGroupName [-SubscriptionId ] - [-DefaultProfile ] [] + [-DefaultProfile ] [-ProgressAction ] [] ``` ### Get ``` Get-AzStackHciArcSetting -ClusterName -Name -ResourceGroupName - [-SubscriptionId ] [-DefaultProfile ] + [-SubscriptionId ] [-DefaultProfile ] [-ProgressAction ] [] ``` ### GetViaIdentity ``` Get-AzStackHciArcSetting -InputObject [-DefaultProfile ] - [] + [-ProgressAction ] [] ``` ## DESCRIPTION @@ -114,6 +114,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/Get-AzStackHciCluster.md b/src/StackHCI/StackHCI/help/Get-AzStackHciCluster.md index 9077981810db..1a965e330899 100644 --- a/src/StackHCI/StackHCI/help/Get-AzStackHciCluster.md +++ b/src/StackHCI/StackHCI/help/Get-AzStackHciCluster.md @@ -15,25 +15,25 @@ Get HCI cluster. ### List (Default) ``` Get-AzStackHciCluster [-SubscriptionId ] [-DefaultProfile ] - [] + [-ProgressAction ] [] ``` ### Get ``` Get-AzStackHciCluster -Name -ResourceGroupName [-SubscriptionId ] - [-DefaultProfile ] [] + [-DefaultProfile ] [-ProgressAction ] [] ``` ### List1 ``` Get-AzStackHciCluster -ResourceGroupName [-SubscriptionId ] [-DefaultProfile ] - [] + [-ProgressAction ] [] ``` ### GetViaIdentity ``` Get-AzStackHciCluster -InputObject [-DefaultProfile ] - [] + [-ProgressAction ] [] ``` ## DESCRIPTION @@ -119,6 +119,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/Get-AzStackHciDeploymentSetting.md b/src/StackHCI/StackHCI/help/Get-AzStackHciDeploymentSetting.md index 7e6021a2c76e..99e39db703fa 100644 --- a/src/StackHCI/StackHCI/help/Get-AzStackHciDeploymentSetting.md +++ b/src/StackHCI/StackHCI/help/Get-AzStackHciDeploymentSetting.md @@ -15,20 +15,20 @@ Get a DeploymentSetting ### List (Default) ``` Get-AzStackHciDeploymentSetting -ClusterName -ResourceGroupName [-SubscriptionId ] - [-DefaultProfile ] [] + [-DefaultProfile ] [-ProgressAction ] [] ``` ### Get ``` Get-AzStackHciDeploymentSetting -ClusterName -ResourceGroupName -SName - [-SubscriptionId ] [-DefaultProfile ] + [-SubscriptionId ] [-DefaultProfile ] [-ProgressAction ] [] ``` ### GetViaIdentity ``` Get-AzStackHciDeploymentSetting -InputObject [-DefaultProfile ] - [] + [-ProgressAction ] [] ``` ## DESCRIPTION @@ -98,6 +98,21 @@ Accept pipeline input: True (ByValue) Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/Get-AzStackHciEdgeDevice.md b/src/StackHCI/StackHCI/help/Get-AzStackHciEdgeDevice.md index 1614c8969bc4..61d7260f1954 100644 --- a/src/StackHCI/StackHCI/help/Get-AzStackHciEdgeDevice.md +++ b/src/StackHCI/StackHCI/help/Get-AzStackHciEdgeDevice.md @@ -15,19 +15,19 @@ Get a EdgeDevice ### List (Default) ``` Get-AzStackHciEdgeDevice -ResourceUri [-DefaultProfile ] - [] + [-ProgressAction ] [] ``` ### Get ``` Get-AzStackHciEdgeDevice -Name -ResourceUri [-DefaultProfile ] - [] + [-ProgressAction ] [] ``` ### GetViaIdentity ``` Get-AzStackHciEdgeDevice -InputObject [-DefaultProfile ] - [] + [-ProgressAction ] [] ``` ## DESCRIPTION @@ -97,6 +97,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceUri The fully qualified Azure Resource manager identifier of the resource. diff --git a/src/StackHCI/StackHCI/help/Get-AzStackHciExtension.md b/src/StackHCI/StackHCI/help/Get-AzStackHciExtension.md index f95b06322867..f00e89e9f480 100644 --- a/src/StackHCI/StackHCI/help/Get-AzStackHciExtension.md +++ b/src/StackHCI/StackHCI/help/Get-AzStackHciExtension.md @@ -15,7 +15,7 @@ Get particular Arc Extension of HCI Cluster. ### List (Default) ``` Get-AzStackHciExtension -ArcSettingName -ClusterName -ResourceGroupName - [-SubscriptionId ] [-DefaultProfile ] + [-SubscriptionId ] [-DefaultProfile ] [-ProgressAction ] [] ``` @@ -23,13 +23,13 @@ Get-AzStackHciExtension -ArcSettingName -ClusterName -Resource ``` Get-AzStackHciExtension -ArcSettingName -ClusterName -Name -ResourceGroupName [-SubscriptionId ] [-DefaultProfile ] - [] + [-ProgressAction ] [] ``` ### GetViaIdentity ``` Get-AzStackHciExtension -InputObject [-DefaultProfile ] - [] + [-ProgressAction ] [] ``` ## DESCRIPTION @@ -130,6 +130,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/Get-AzStackHciSecuritySetting.md b/src/StackHCI/StackHCI/help/Get-AzStackHciSecuritySetting.md index 40c237809966..d520207f797e 100644 --- a/src/StackHCI/StackHCI/help/Get-AzStackHciSecuritySetting.md +++ b/src/StackHCI/StackHCI/help/Get-AzStackHciSecuritySetting.md @@ -15,20 +15,20 @@ Get a SecuritySetting ### List (Default) ``` Get-AzStackHciSecuritySetting -ClusterName -ResourceGroupName [-SubscriptionId ] - [-DefaultProfile ] [] + [-DefaultProfile ] [-ProgressAction ] [] ``` ### Get ``` Get-AzStackHciSecuritySetting -ClusterName -ResourceGroupName -SName - [-SubscriptionId ] [-DefaultProfile ] + [-SubscriptionId ] [-DefaultProfile ] [-ProgressAction ] [] ``` ### GetViaIdentity ``` Get-AzStackHciSecuritySetting -InputObject [-DefaultProfile ] - [] + [-ProgressAction ] [] ``` ## DESCRIPTION @@ -98,6 +98,21 @@ Accept pipeline input: True (ByValue) Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/Get-AzStackHciUpdate.md b/src/StackHCI/StackHCI/help/Get-AzStackHciUpdate.md index 7eda7edefd69..09761967f93d 100644 --- a/src/StackHCI/StackHCI/help/Get-AzStackHciUpdate.md +++ b/src/StackHCI/StackHCI/help/Get-AzStackHciUpdate.md @@ -15,20 +15,20 @@ Get specified Update ### List (Default) ``` Get-AzStackHciUpdate -ClusterName -ResourceGroupName [-SubscriptionId ] - [-DefaultProfile ] [] + [-DefaultProfile ] [-ProgressAction ] [] ``` ### Get ``` Get-AzStackHciUpdate -ClusterName -Name -ResourceGroupName - [-SubscriptionId ] [-DefaultProfile ] + [-SubscriptionId ] [-DefaultProfile ] [-ProgressAction ] [] ``` ### GetViaIdentity ``` Get-AzStackHciUpdate -InputObject [-DefaultProfile ] - [] + [-ProgressAction ] [] ``` ## DESCRIPTION @@ -107,6 +107,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/Get-AzStackHciUpdateRun.md b/src/StackHCI/StackHCI/help/Get-AzStackHciUpdateRun.md index 9f313808797f..71aa76ae70b5 100644 --- a/src/StackHCI/StackHCI/help/Get-AzStackHciUpdateRun.md +++ b/src/StackHCI/StackHCI/help/Get-AzStackHciUpdateRun.md @@ -15,20 +15,20 @@ Get the Update run for a specified update ### List (Default) ``` Get-AzStackHciUpdateRun -ClusterName -ResourceGroupName [-SubscriptionId ] - -UpdateName [-DefaultProfile ] [] + -UpdateName [-DefaultProfile ] [-ProgressAction ] [] ``` ### Get ``` Get-AzStackHciUpdateRun -ClusterName -Name -ResourceGroupName [-SubscriptionId ] -UpdateName [-DefaultProfile ] - [] + [-ProgressAction ] [] ``` ### GetViaIdentity ``` Get-AzStackHciUpdateRun -InputObject [-DefaultProfile ] - [] + [-ProgressAction ] [] ``` ## DESCRIPTION @@ -107,6 +107,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/Get-AzStackHciUpdateSummary.md b/src/StackHCI/StackHCI/help/Get-AzStackHciUpdateSummary.md index 1a956f2376a1..aebc0c7a011a 100644 --- a/src/StackHCI/StackHCI/help/Get-AzStackHciUpdateSummary.md +++ b/src/StackHCI/StackHCI/help/Get-AzStackHciUpdateSummary.md @@ -15,19 +15,19 @@ Get all Update summaries under the HCI cluster ### Get (Default) ``` Get-AzStackHciUpdateSummary -ClusterName -ResourceGroupName [-SubscriptionId ] - [-DefaultProfile ] [] + [-DefaultProfile ] [-ProgressAction ] [] ``` ### List ``` Get-AzStackHciUpdateSummary -ClusterName -ResourceGroupName [-SubscriptionId ] - [-DefaultProfile ] [] + [-DefaultProfile ] [-ProgressAction ] [] ``` ### GetViaIdentity ``` Get-AzStackHciUpdateSummary -InputObject [-DefaultProfile ] - [] + [-ProgressAction ] [] ``` ## DESCRIPTION @@ -97,6 +97,21 @@ Accept pipeline input: True (ByValue) Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/Install-AzStackHCIRemoteSupport.md b/src/StackHCI/StackHCI/help/Install-AzStackHCIRemoteSupport.md index acc7dcc83c75..68de69270b67 100644 --- a/src/StackHCI/StackHCI/help/Install-AzStackHCIRemoteSupport.md +++ b/src/StackHCI/StackHCI/help/Install-AzStackHCIRemoteSupport.md @@ -13,7 +13,7 @@ Installs Remote Support. ## SYNTAX ``` -Install-AzStackHCIRemoteSupport [-WhatIf] [-Confirm] [] +Install-AzStackHCIRemoteSupport [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -49,6 +49,21 @@ Installs Remort Support ## PARAMETERS +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -Confirm Prompts you for confirmation before running the cmdlet. diff --git a/src/StackHCI/StackHCI/help/Invoke-AzStackHciConsentAndInstallDefaultExtension.md b/src/StackHCI/StackHCI/help/Invoke-AzStackHciConsentAndInstallDefaultExtension.md index 66f8d0221b1f..3e9a2a24919f 100644 --- a/src/StackHCI/StackHCI/help/Invoke-AzStackHciConsentAndInstallDefaultExtension.md +++ b/src/StackHCI/StackHCI/help/Invoke-AzStackHciConsentAndInstallDefaultExtension.md @@ -15,14 +15,14 @@ Add consent time for default extensions and initiate extensions installation ### And (Default) ``` Invoke-AzStackHciConsentAndInstallDefaultExtension -ClusterName -ResourceGroupName - [-SubscriptionId ] [-DefaultProfile ] [-WhatIf] + [-SubscriptionId ] [-DefaultProfile ] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### AndViaIdentity ``` Invoke-AzStackHciConsentAndInstallDefaultExtension -InputObject - [-DefaultProfile ] [-WhatIf] [-Confirm] [] + [-DefaultProfile ] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -93,6 +93,21 @@ Accept pipeline input: True (ByValue) Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/Invoke-AzStackHciExtendClusterSoftwareAssuranceBenefit.md b/src/StackHCI/StackHCI/help/Invoke-AzStackHciExtendClusterSoftwareAssuranceBenefit.md index 6a84d67d373c..fa26f40f2111 100644 --- a/src/StackHCI/StackHCI/help/Invoke-AzStackHciExtendClusterSoftwareAssuranceBenefit.md +++ b/src/StackHCI/StackHCI/help/Invoke-AzStackHciExtendClusterSoftwareAssuranceBenefit.md @@ -16,14 +16,14 @@ Extends Software Assurance Benefit to a cluster ``` Invoke-AzStackHciExtendClusterSoftwareAssuranceBenefit -ClusterName -ResourceGroupName [-SubscriptionId ] [-SoftwareAssuranceIntent ] [-DefaultProfile ] - [-AsJob] [-NoWait] [-WhatIf] [-Confirm] [] + [-AsJob] [-NoWait] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### Extend ``` Invoke-AzStackHciExtendClusterSoftwareAssuranceBenefit -ClusterName -ResourceGroupName [-SubscriptionId ] -SoftwareAssuranceChangeRequest - [-DefaultProfile ] [-AsJob] [-NoWait] [-WhatIf] [-Confirm] + [-DefaultProfile ] [-AsJob] [-NoWait] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` @@ -31,14 +31,14 @@ Invoke-AzStackHciExtendClusterSoftwareAssuranceBenefit -ClusterName -Re ``` Invoke-AzStackHciExtendClusterSoftwareAssuranceBenefit -InputObject [-SoftwareAssuranceIntent ] [-DefaultProfile ] [-AsJob] [-NoWait] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### ExtendViaIdentity ``` Invoke-AzStackHciExtendClusterSoftwareAssuranceBenefit -InputObject -SoftwareAssuranceChangeRequest [-DefaultProfile ] [-AsJob] - [-NoWait] [-WhatIf] [-Confirm] [] + [-NoWait] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -139,6 +139,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/Invoke-AzStackHciUpdate.md b/src/StackHCI/StackHCI/help/Invoke-AzStackHciUpdate.md index 0f19ca1fef5c..7b1c62107aeb 100644 --- a/src/StackHCI/StackHCI/help/Invoke-AzStackHciUpdate.md +++ b/src/StackHCI/StackHCI/help/Invoke-AzStackHciUpdate.md @@ -16,13 +16,13 @@ Apply Update ``` Invoke-AzStackHciUpdate -ClusterName -Name -ResourceGroupName [-SubscriptionId ] [-DefaultProfile ] [-AsJob] [-NoWait] [-PassThru] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### PostViaIdentity ``` Invoke-AzStackHciUpdate -InputObject [-DefaultProfile ] [-AsJob] [-NoWait] - [-PassThru] [-WhatIf] [-Confirm] [] + [-PassThru] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -146,6 +146,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/New-AzStackHciArcSetting.md b/src/StackHCI/StackHCI/help/New-AzStackHciArcSetting.md index 244f54b7dfae..86e6d4106ddf 100644 --- a/src/StackHCI/StackHCI/help/New-AzStackHciArcSetting.md +++ b/src/StackHCI/StackHCI/help/New-AzStackHciArcSetting.md @@ -16,7 +16,7 @@ Create ArcSetting for HCI cluster. New-AzStackHciArcSetting -ClusterName -ResourceGroupName [-SubscriptionId ] [-ArcApplicationClientId ] [-ArcApplicationObjectId ] [-ArcApplicationTenantId ] [-ArcInstanceResourceGroup ] [-ArcServicePrincipalObjectId ] [-ConnectivityProperty ] - [-DefaultProfile ] [-WhatIf] [-Confirm] [] + [-DefaultProfile ] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -162,6 +162,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/New-AzStackHciCluster.md b/src/StackHCI/StackHCI/help/New-AzStackHciCluster.md index afe4bc9e9499..bac8ba4fe904 100644 --- a/src/StackHCI/StackHCI/help/New-AzStackHciCluster.md +++ b/src/StackHCI/StackHCI/help/New-AzStackHciCluster.md @@ -20,7 +20,7 @@ New-AzStackHciCluster -Name -ResourceGroupName [-SubscriptionI [-DesiredPropertyWindowsServerSubscription ] [-IdentityType ] [-IdentityUserAssignedIdentity ] [-SoftwareAssurancePropertySoftwareAssuranceIntent ] [-Tag ] - [-DefaultProfile ] [-WhatIf] [-Confirm] [] + [-DefaultProfile ] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -30,7 +30,7 @@ Create an HCI cluster. ### Example 1: ```powershell -New-AzStackHciCluster -Name "myCluster" -ResourceGroupName "test-rg" -AadTenantId "00001111-aaaa-2222-bbbb-3333cccc4444" -AadClientId "24a6e53d-04e5-44d2-b7cc-1b732a847dfc" -Location "eastus" +New-AzStackHciCluster -Name "myCluster" -ResourceGroupName "test-rg" -AadTenantId "c76bd4d1-bea3-45ea-be1b-4a745a675d07" -AadClientId "24a6e53d-04e5-44d2-b7cc-1b732a847dfc" -Location "eastus" ``` ```output @@ -43,7 +43,7 @@ This command creates a Stack HCI cluster ### Example 2: ```powershell -New-AzStackHciCluster -Name "myCluster2" -ResourceGroupName "test-rg" -AadTenantId "00001111-aaaa-2222-bbbb-3333cccc4444" -AadClientId "24a6e53d-04e5-44d2-b7cc-1b732a847dfc" -Location "westeurope" -DesiredPropertyDiagnosticLevel "Off" -DesiredPropertyWindowsServerSubscription "Enabled" +New-AzStackHciCluster -Name "myCluster2" -ResourceGroupName "test-rg" -AadTenantId "c76bd4d1-bea3-45ea-be1b-4a745a675d07" -AadClientId "24a6e53d-04e5-44d2-b7cc-1b732a847dfc" -Location "westeurope" -DesiredPropertyDiagnosticLevel "Off" -DesiredPropertyWindowsServerSubscription "Enabled" ``` ```output @@ -240,6 +240,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/New-AzStackHciDeploymentSetting.md b/src/StackHCI/StackHCI/help/New-AzStackHciDeploymentSetting.md index 5a8deb409bec..f9065facfe30 100644 --- a/src/StackHCI/StackHCI/help/New-AzStackHciDeploymentSetting.md +++ b/src/StackHCI/StackHCI/help/New-AzStackHciDeploymentSetting.md @@ -16,7 +16,7 @@ Create a DeploymentSetting New-AzStackHciDeploymentSetting -ClusterName -ResourceGroupName -SName [-SubscriptionId ] [-ArcNodeResourceId ] [-DeploymentConfigurationScaleUnit ] [-DeploymentConfigurationVersion ] [-DeploymentMode ] [-OperationType ] - [-DefaultProfile ] [-AsJob] [-NoWait] [-WhatIf] [-Confirm] + [-DefaultProfile ] [-AsJob] [-NoWait] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` @@ -177,6 +177,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/New-AzStackHciEdgeDevice.md b/src/StackHCI/StackHCI/help/New-AzStackHciEdgeDevice.md index 4e09529c9929..736330c3b464 100644 --- a/src/StackHCI/StackHCI/help/New-AzStackHciEdgeDevice.md +++ b/src/StackHCI/StackHCI/help/New-AzStackHciEdgeDevice.md @@ -14,7 +14,7 @@ Create a EdgeDevice ``` New-AzStackHciEdgeDevice -ResourceUri [-DefaultProfile ] [-AsJob] [-NoWait] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -83,6 +83,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceUri The fully qualified Azure Resource manager identifier of the resource. diff --git a/src/StackHCI/StackHCI/help/New-AzStackHciExtension.md b/src/StackHCI/StackHCI/help/New-AzStackHciExtension.md index dc88b4438bda..050fd512f359 100644 --- a/src/StackHCI/StackHCI/help/New-AzStackHciExtension.md +++ b/src/StackHCI/StackHCI/help/New-AzStackHciExtension.md @@ -19,7 +19,7 @@ New-AzStackHciExtension -ArcSettingName -ClusterName -Name ] [-ExtensionParameterPublisher ] [-ExtensionParameterSetting ] [-ExtensionParameterType ] [-ExtensionParameterTypeHandlerVersion ] [-DefaultProfile ] [-AsJob] [-NoWait] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -269,6 +269,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/New-AzStackHciSecuritySetting.md b/src/StackHCI/StackHCI/help/New-AzStackHciSecuritySetting.md index c741a92c1815..fabd88d5ea3e 100644 --- a/src/StackHCI/StackHCI/help/New-AzStackHciSecuritySetting.md +++ b/src/StackHCI/StackHCI/help/New-AzStackHciSecuritySetting.md @@ -17,7 +17,7 @@ New-AzStackHciSecuritySetting -ClusterName -ResourceGroupName [-ProvisioningState ] [-SecuredCoreComplianceAssignment ] [-SmbEncryptionForIntraClusterTrafficComplianceAssignment ] [-WdacComplianceAssignment ] [-DefaultProfile ] [-AsJob] [-NoWait] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -101,6 +101,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ProvisioningState The status of the last operation. diff --git a/src/StackHCI/StackHCI/help/Register-AzStackHCI.md b/src/StackHCI/StackHCI/help/Register-AzStackHCI.md index 7bd183e293d7..80ce41ea627e 100644 --- a/src/StackHCI/StackHCI/help/Register-AzStackHCI.md +++ b/src/StackHCI/StackHCI/help/Register-AzStackHCI.md @@ -18,7 +18,7 @@ Register-AzStackHCI [-SubscriptionId] [-Region] [[-ResourceNam [[-AccountId] ] [[-EnvironmentName] ] [[-ComputerName] ] [[-CertificateThumbprint] ] [-RepairRegistration] [-UseDeviceAuthentication] [[-Credential] ] [-IsWAC] [[-ArcServerResourceGroupName] ] - [[-ArcSpnCredential] ] [[-LogsDirectory] ] + [[-ArcSpnCredential] ] [[-LogsDirectory] ] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` @@ -36,7 +36,7 @@ Register-AzStackHCI -SubscriptionId "12a0f531-56cb-4340-9501-257726d741fd" -Regi Result: Success ResourceId: /subscriptions/12a0f531-56cb-4340-9501-257726d741fd/resourceGroups/DemoHCICluster1-rg/providers/Microsoft.AzureStackHCI/clusters/DemoHCICluster1 PortalResourceURL: https://portal.azure.com/#@c31c0dbb-ce27-4c78-ad26-a5f717c14557/resource/subscriptions/12a0f531-56cb-4340-9501-257726d741fd/resourceGroups/DemoHCICluster1-rg/providers/Microsoft.AzureStackHCI/clusters/DemoHCICluster1/overview -PortalAADAppPermissionsURL: https://portal.azure.com/#blade/Microsoft_AAD_RegisteredApps/ApplicationMenuBlade/CallAnAPI/appId/00001111-aaaa-2222-bbbb-3333cccc4444/isMSAApp/ +PortalAADAppPermissionsURL: https://portal.azure.com/#blade/Microsoft_AAD_RegisteredApps/ApplicationMenuBlade/CallAnAPI/appId/980be58d-578c-4cff-b4cd-43e9c3a77826/isMSAApp/ ``` Invoking on one of the cluster node. @@ -50,7 +50,7 @@ Register-AzStackHCI -SubscriptionId "12a0f531-56cb-4340-9501-257726d741fd" -Comp Result: Success ResourceId: /subscriptions/12a0f531-56cb-4340-9501-257726d741fd/resourceGroups/DemoHCICluster2-rg/providers/Microsoft.AzureStackHCI/clusters/DemoHCICluster2 PortalResourceURL: https://portal.azure.com/#@c31c0dbb-ce27-4c78-ad26-a5f717c14557/resource/subscriptions/12a0f531-56cb-4340-9501-257726d741fd/resourceGroups/DemoHCICluster2-rg/providers/Microsoft.AzureStackHCI/clusters/DemoHCICluster2/overview -PortalAADAppPermissionsURL: https://portal.azure.com/#blade/Microsoft_AAD_RegisteredApps/ApplicationMenuBlade/CallAnAPI/appId/00001111-aaaa-2222-bbbb-3333cccc4444/isMSAApp/ +PortalAADAppPermissionsURL: https://portal.azure.com/#blade/Microsoft_AAD_RegisteredApps/ApplicationMenuBlade/CallAnAPI/appId/950be58d-578c-4cff-b4cd-43e9c3a77866/isMSAApp/ ``` Invoking from the management node. @@ -64,7 +64,7 @@ Register-AzStackHCI -SubscriptionId "12a0f531-56cb-4340-9501-257726d741fd" -ArmA Result: PendingForAdminConsent ResourceId: /subscriptions/12a0f531-56cb-4340-9501-257726d741fd/resourceGroups/DemoHCIRG/providers/Microsoft.AzureStackHCI/clusters/DemoHCICluster3 PortalResourceURL: https://portal.azure.com/#@c31c0dbb-ce27-4c78-ad26-a5f717c14557/resource/subscriptions/12a0f531-56cb-4340-9501-257726d741fd/resourceGroups/DemoHCIRG/providers/Microsoft.AzureStackHCI/clusters/DemoHCICluster3/overview -PortalAADAppPermissionsURL: https://portal.azure.com/#blade/Microsoft_AAD_RegisteredApps/ApplicationMenuBlade/CallAnAPI/appId/00001111-aaaa-2222-bbbb-3333cccc4444/isMSAApp/ +PortalAADAppPermissionsURL: https://portal.azure.com/#blade/Microsoft_AAD_RegisteredApps/ApplicationMenuBlade/CallAnAPI/appId/980be58d-578c-4cff-b4cd-43e9c3a77866/isMSAApp/ ``` Invoking from WAC. @@ -78,7 +78,7 @@ Register-AzStackHCI -SubscriptionId "12a0f531-56cb-4340-9501-257726d741fd" -Regi Result: Success ResourceId: /subscriptions/12a0f531-56cb-4340-9501-257726d741fd/resourceGroups/HciRG/providers/Microsoft.AzureStackHCI/clusters/HciCluster1 PortalResourceURL: https://portal.azure.com/#@c31c0dbb-ce27-4c78-ad26-a5f717c14557/resource/subscriptions/12a0f531-56cb-4340-9501-257726d741fd/resourceGroups/HciRG/providers/Microsoft.AzureStackHCI/clusters/HciCluster1/overview -PortalAADAppPermissionsURL: https://portal.azure.com/#blade/Microsoft_AAD_RegisteredApps/ApplicationMenuBlade/CallAnAPI/appId/00001111-aaaa-2222-bbbb-3333cccc4444/isMSAApp/ +PortalAADAppPermissionsURL: https://portal.azure.com/#blade/Microsoft_AAD_RegisteredApps/ApplicationMenuBlade/CallAnAPI/appId/990be58d-578c-4cff-b4cd-43e9c3a77866/isMSAApp/ ``` Invoking with all the parameters. @@ -245,6 +245,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -Region Specifies the Region to create the resource. Region is a Mandatory parameter. diff --git a/src/StackHCI/StackHCI/help/Remove-AzStackHCIRemoteSupport.md b/src/StackHCI/StackHCI/help/Remove-AzStackHCIRemoteSupport.md index 0d6beced8b79..4f76332ba690 100644 --- a/src/StackHCI/StackHCI/help/Remove-AzStackHCIRemoteSupport.md +++ b/src/StackHCI/StackHCI/help/Remove-AzStackHCIRemoteSupport.md @@ -13,7 +13,7 @@ Removes Remote Support. ## SYNTAX ``` -Remove-AzStackHCIRemoteSupport [-WhatIf] [-Confirm] [] +Remove-AzStackHCIRemoteSupport [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -40,6 +40,21 @@ Removes Remote Support ## PARAMETERS +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -Confirm Prompts you for confirmation before running the cmdlet. diff --git a/src/StackHCI/StackHCI/help/Remove-AzStackHCIVMAttestation.md b/src/StackHCI/StackHCI/help/Remove-AzStackHCIVMAttestation.md index efcc75ae35eb..e16be3c91414 100644 --- a/src/StackHCI/StackHCI/help/Remove-AzStackHCIVMAttestation.md +++ b/src/StackHCI/StackHCI/help/Remove-AzStackHCIVMAttestation.md @@ -14,19 +14,19 @@ Remove-AzStackHCIVMAttestation removes guests from AzureStack HCI IMDS Attestati ### VMName (Default) ``` -Remove-AzStackHCIVMAttestation [-VMName] [-Force] [-WhatIf] +Remove-AzStackHCIVMAttestation [-VMName] [-Force] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### VMObject ``` -Remove-AzStackHCIVMAttestation [-Force] [-VM] [-WhatIf] +Remove-AzStackHCIVMAttestation [-Force] [-VM] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### RemoveAll ``` -Remove-AzStackHCIVMAttestation [-Force] [-RemoveAll] [-WhatIf] [-Confirm] +Remove-AzStackHCIVMAttestation [-Force] [-RemoveAll] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` @@ -71,6 +71,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -RemoveAll Specifies a switch that will remove all guest VMs from Attestation on the current node diff --git a/src/StackHCI/StackHCI/help/Remove-AzStackHciArcSetting.md b/src/StackHCI/StackHCI/help/Remove-AzStackHciArcSetting.md index f99941e25be0..45c2312b5ac6 100644 --- a/src/StackHCI/StackHCI/help/Remove-AzStackHciArcSetting.md +++ b/src/StackHCI/StackHCI/help/Remove-AzStackHciArcSetting.md @@ -16,13 +16,13 @@ Delete ArcSetting resource details of HCI Cluster. ``` Remove-AzStackHciArcSetting -ClusterName -Name -ResourceGroupName [-SubscriptionId ] [-DefaultProfile ] [-AsJob] [-NoWait] [-PassThru] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### DeleteViaIdentity ``` Remove-AzStackHciArcSetting -InputObject [-DefaultProfile ] [-AsJob] [-NoWait] - [-PassThru] [-WhatIf] [-Confirm] [] + [-PassThru] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -146,6 +146,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/Remove-AzStackHciCluster.md b/src/StackHCI/StackHCI/help/Remove-AzStackHciCluster.md index 82c95583f5c3..4e24a6eb166d 100644 --- a/src/StackHCI/StackHCI/help/Remove-AzStackHciCluster.md +++ b/src/StackHCI/StackHCI/help/Remove-AzStackHciCluster.md @@ -15,14 +15,14 @@ Delete an HCI cluster. ### Delete (Default) ``` Remove-AzStackHciCluster -Name -ResourceGroupName [-SubscriptionId ] - [-DefaultProfile ] [-AsJob] [-NoWait] [-PassThru] [-WhatIf] + [-DefaultProfile ] [-AsJob] [-NoWait] [-PassThru] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### DeleteViaIdentity ``` Remove-AzStackHciCluster -InputObject [-DefaultProfile ] [-AsJob] [-NoWait] - [-PassThru] [-WhatIf] [-Confirm] [] + [-PassThru] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -131,6 +131,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/Remove-AzStackHciDeploymentSetting.md b/src/StackHCI/StackHCI/help/Remove-AzStackHciDeploymentSetting.md index 7b08d2866c66..7b40ae3381f9 100644 --- a/src/StackHCI/StackHCI/help/Remove-AzStackHciDeploymentSetting.md +++ b/src/StackHCI/StackHCI/help/Remove-AzStackHciDeploymentSetting.md @@ -16,13 +16,13 @@ Delete a DeploymentSetting ``` Remove-AzStackHciDeploymentSetting -ClusterName -ResourceGroupName -SName [-SubscriptionId ] [-DefaultProfile ] [-AsJob] [-NoWait] [-PassThru] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### DeleteViaIdentity ``` Remove-AzStackHciDeploymentSetting -InputObject [-DefaultProfile ] [-AsJob] - [-NoWait] [-PassThru] [-WhatIf] [-Confirm] [] + [-NoWait] [-PassThru] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -131,6 +131,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/Remove-AzStackHciEdgeDevice.md b/src/StackHCI/StackHCI/help/Remove-AzStackHciEdgeDevice.md index f7248a186f21..85d8408064e4 100644 --- a/src/StackHCI/StackHCI/help/Remove-AzStackHciEdgeDevice.md +++ b/src/StackHCI/StackHCI/help/Remove-AzStackHciEdgeDevice.md @@ -15,13 +15,13 @@ Delete a EdgeDevice ### Delete (Default) ``` Remove-AzStackHciEdgeDevice -Name -ResourceUri [-DefaultProfile ] [-AsJob] - [-NoWait] [-PassThru] [-WhatIf] [-Confirm] [] + [-NoWait] [-PassThru] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### DeleteViaIdentity ``` Remove-AzStackHciEdgeDevice -InputObject [-DefaultProfile ] [-AsJob] [-NoWait] - [-PassThru] [-WhatIf] [-Confirm] [] + [-PassThru] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -130,6 +130,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceUri The fully qualified Azure Resource manager identifier of the resource. diff --git a/src/StackHCI/StackHCI/help/Remove-AzStackHciExtension.md b/src/StackHCI/StackHCI/help/Remove-AzStackHciExtension.md index 6530b0ee6ffd..b128599060fa 100644 --- a/src/StackHCI/StackHCI/help/Remove-AzStackHciExtension.md +++ b/src/StackHCI/StackHCI/help/Remove-AzStackHciExtension.md @@ -16,13 +16,13 @@ Delete particular Arc Extension of HCI Cluster. ``` Remove-AzStackHciExtension -ArcSettingName -ClusterName -Name -ResourceGroupName [-SubscriptionId ] [-DefaultProfile ] [-AsJob] [-NoWait] - [-PassThru] [-WhatIf] [-Confirm] [] + [-PassThru] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### DeleteViaIdentity ``` Remove-AzStackHciExtension -InputObject [-DefaultProfile ] [-AsJob] [-NoWait] - [-PassThru] [-WhatIf] [-Confirm] [] + [-PassThru] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -168,6 +168,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/Remove-AzStackHciSecuritySetting.md b/src/StackHCI/StackHCI/help/Remove-AzStackHciSecuritySetting.md index f8392d05eb96..8d1498ea0d4e 100644 --- a/src/StackHCI/StackHCI/help/Remove-AzStackHciSecuritySetting.md +++ b/src/StackHCI/StackHCI/help/Remove-AzStackHciSecuritySetting.md @@ -16,13 +16,13 @@ Delete a SecuritySetting ``` Remove-AzStackHciSecuritySetting -ClusterName -ResourceGroupName -SName [-SubscriptionId ] [-DefaultProfile ] [-AsJob] [-NoWait] [-PassThru] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### DeleteViaIdentity ``` Remove-AzStackHciSecuritySetting -InputObject [-DefaultProfile ] [-AsJob] - [-NoWait] [-PassThru] [-WhatIf] [-Confirm] [] + [-NoWait] [-PassThru] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -131,6 +131,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/Remove-AzStackHciUpdate.md b/src/StackHCI/StackHCI/help/Remove-AzStackHciUpdate.md index 4033a65c08d6..4f3e467c2237 100644 --- a/src/StackHCI/StackHCI/help/Remove-AzStackHciUpdate.md +++ b/src/StackHCI/StackHCI/help/Remove-AzStackHciUpdate.md @@ -16,13 +16,13 @@ Delete specified Update ``` Remove-AzStackHciUpdate -ClusterName -Name -ResourceGroupName [-SubscriptionId ] [-DefaultProfile ] [-AsJob] [-NoWait] [-PassThru] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### DeleteViaIdentity ``` Remove-AzStackHciUpdate -InputObject [-DefaultProfile ] [-AsJob] [-NoWait] - [-PassThru] [-WhatIf] [-Confirm] [] + [-PassThru] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -146,6 +146,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/Remove-AzStackHciUpdateRun.md b/src/StackHCI/StackHCI/help/Remove-AzStackHciUpdateRun.md index 11ce1018d1e0..bc8708827e3f 100644 --- a/src/StackHCI/StackHCI/help/Remove-AzStackHciUpdateRun.md +++ b/src/StackHCI/StackHCI/help/Remove-AzStackHciUpdateRun.md @@ -16,13 +16,13 @@ Delete specified Update Run ``` Remove-AzStackHciUpdateRun -ClusterName -Name -ResourceGroupName [-SubscriptionId ] -UpdateName [-DefaultProfile ] [-AsJob] [-NoWait] [-PassThru] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### DeleteViaIdentity ``` Remove-AzStackHciUpdateRun -InputObject [-DefaultProfile ] [-AsJob] [-NoWait] - [-PassThru] [-WhatIf] [-Confirm] [] + [-PassThru] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -146,6 +146,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/Remove-AzStackHciUpdateSummary.md b/src/StackHCI/StackHCI/help/Remove-AzStackHciUpdateSummary.md index d89014b1faa1..94e9846e1cc9 100644 --- a/src/StackHCI/StackHCI/help/Remove-AzStackHciUpdateSummary.md +++ b/src/StackHCI/StackHCI/help/Remove-AzStackHciUpdateSummary.md @@ -15,14 +15,14 @@ Delete Update Summaries ### Delete (Default) ``` Remove-AzStackHciUpdateSummary -ClusterName -ResourceGroupName [-SubscriptionId ] - [-DefaultProfile ] [-AsJob] [-NoWait] [-PassThru] [-WhatIf] + [-DefaultProfile ] [-AsJob] [-NoWait] [-PassThru] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### DeleteViaIdentity ``` Remove-AzStackHciUpdateSummary -InputObject [-DefaultProfile ] [-AsJob] [-NoWait] - [-PassThru] [-WhatIf] [-Confirm] [] + [-PassThru] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -131,6 +131,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/Set-AzStackHCI.md b/src/StackHCI/StackHCI/help/Set-AzStackHCI.md index f76102aab409..a79a90aa8ab9 100644 --- a/src/StackHCI/StackHCI/help/Set-AzStackHCI.md +++ b/src/StackHCI/StackHCI/help/Set-AzStackHCI.md @@ -16,7 +16,7 @@ Set-AzStackHCI modifies resource properties of the Microsoft.AzureStackHCI cloud Set-AzStackHCI [[-ComputerName] ] [-Credential ] [-ResourceId ] [-EnableWSSubscription ] [-DiagnosticLevel ] [-TenantId ] [-ArmAccessToken ] [-AccountId ] [-EnvironmentName ] [-UseDeviceAuthentication] - [-Force] [-WhatIf] [-Confirm] [] + [-Force] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -175,6 +175,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceId Specifies the fully qualified resource ID, including the subscription, as in the following example: `/Subscriptions/`subscription ID`/providers/Microsoft.AzureStackHCI/clusters/MyCluster` diff --git a/src/StackHCI/StackHCI/help/Set-AzStackHciDeploymentSetting.md b/src/StackHCI/StackHCI/help/Set-AzStackHciDeploymentSetting.md index afb1eb5208dc..61d46565c098 100644 --- a/src/StackHCI/StackHCI/help/Set-AzStackHciDeploymentSetting.md +++ b/src/StackHCI/StackHCI/help/Set-AzStackHciDeploymentSetting.md @@ -16,7 +16,7 @@ Create a DeploymentSetting Set-AzStackHciDeploymentSetting -ClusterName -ResourceGroupName -SName [-SubscriptionId ] [-ArcNodeResourceId ] [-DeploymentConfigurationScaleUnit ] [-DeploymentConfigurationVersion ] [-DeploymentMode ] [-OperationType ] - [-DefaultProfile ] [-AsJob] [-NoWait] [-WhatIf] [-Confirm] + [-DefaultProfile ] [-AsJob] [-NoWait] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` @@ -171,6 +171,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/Set-AzStackHciEdgeDevice.md b/src/StackHCI/StackHCI/help/Set-AzStackHciEdgeDevice.md index ff205718732e..c364144e9ddf 100644 --- a/src/StackHCI/StackHCI/help/Set-AzStackHciEdgeDevice.md +++ b/src/StackHCI/StackHCI/help/Set-AzStackHciEdgeDevice.md @@ -14,7 +14,7 @@ Create a EdgeDevice ``` Set-AzStackHciEdgeDevice -Name -ResourceUri [-DefaultProfile ] [-AsJob] [-NoWait] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -98,6 +98,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceUri The fully qualified Azure Resource manager identifier of the resource. diff --git a/src/StackHCI/StackHCI/help/Set-AzStackHciSecuritySetting.md b/src/StackHCI/StackHCI/help/Set-AzStackHciSecuritySetting.md index b52c3f5a5fae..6bbad06e7aa8 100644 --- a/src/StackHCI/StackHCI/help/Set-AzStackHciSecuritySetting.md +++ b/src/StackHCI/StackHCI/help/Set-AzStackHciSecuritySetting.md @@ -18,7 +18,7 @@ Set-AzStackHciSecuritySetting -ClusterName -ResourceGroupName [-SecuredCoreComplianceAssignment ] [-SmbEncryptionForIntraClusterTrafficComplianceAssignment ] [-WdacComplianceAssignment ] [-DefaultProfile ] [-AsJob] [-NoWait] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -102,6 +102,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ProvisioningState The status of the last operation. diff --git a/src/StackHCI/StackHCI/help/Set-AzStackHciUpdate.md b/src/StackHCI/StackHCI/help/Set-AzStackHciUpdate.md index 747bb8e00d65..4db656a6bcd4 100644 --- a/src/StackHCI/StackHCI/help/Set-AzStackHciUpdate.md +++ b/src/StackHCI/StackHCI/help/Set-AzStackHciUpdate.md @@ -22,7 +22,7 @@ Set-AzStackHciUpdate -ClusterName -Name -ResourceGroupName ] [-PackageType ] [-Prerequisite ] [-Publisher ] [-RebootRequired ] [-ReleaseLink ] [-State ] [-UpdateStatePropertyNotifyMessage ] [-UpdateStatePropertyProgressPercentage ] - [-Version ] [-DefaultProfile ] [-WhatIf] [-Confirm] + [-Version ] [-DefaultProfile ] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` @@ -30,7 +30,7 @@ Set-AzStackHciUpdate -ClusterName -Name -ResourceGroupName -Name -ResourceGroupName [-SubscriptionId ] -UpdateProperty [-DefaultProfile ] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -325,6 +325,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -Publisher Publisher of the update package. diff --git a/src/StackHCI/StackHCI/help/Set-AzStackHciUpdateRun.md b/src/StackHCI/StackHCI/help/Set-AzStackHciUpdateRun.md index 030e3a17e799..958ee1fe3ed5 100644 --- a/src/StackHCI/StackHCI/help/Set-AzStackHciUpdateRun.md +++ b/src/StackHCI/StackHCI/help/Set-AzStackHciUpdateRun.md @@ -19,7 +19,7 @@ Set-AzStackHciUpdateRun -ClusterName -Name -ResourceGroupName [-ProgressDescription ] [-ProgressEndTimeUtc ] [-ProgressErrorMessage ] [-ProgressLastUpdatedTimeUtc ] [-ProgressName ] [-ProgressStartTimeUtc ] [-ProgressStatus ] [-ProgressStep ] [-State ] - [-TimeStarted ] [-DefaultProfile ] [-WhatIf] + [-TimeStarted ] [-DefaultProfile ] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` @@ -27,7 +27,7 @@ Set-AzStackHciUpdateRun -ClusterName -Name -ResourceGroupName ``` Set-AzStackHciUpdateRun -ClusterName -Name -ResourceGroupName -UpdateName [-SubscriptionId ] -UpdateRunsProperty [-DefaultProfile ] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -135,6 +135,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ProgressDescription More detailed description of the step. diff --git a/src/StackHCI/StackHCI/help/Set-AzStackHciUpdateSummary.md b/src/StackHCI/StackHCI/help/Set-AzStackHciUpdateSummary.md index 57839e896205..e700570110c9 100644 --- a/src/StackHCI/StackHCI/help/Set-AzStackHciUpdateSummary.md +++ b/src/StackHCI/StackHCI/help/Set-AzStackHciUpdateSummary.md @@ -19,13 +19,13 @@ Set-AzStackHciUpdateSummary -ClusterName -ResourceGroupName [- [-HealthCheckDate ] [-HealthCheckResult ] [-HealthState ] [-LastChecked ] [-LastUpdated ] [-Location ] [-OemFamily ] [-PackageVersion ] [-State ] - [-DefaultProfile ] [-WhatIf] [-Confirm] [] + [-DefaultProfile ] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### Put ``` Set-AzStackHciUpdateSummary -ClusterName -ResourceGroupName [-SubscriptionId ] - -UpdateLocationProperty [-DefaultProfile ] + -UpdateLocationProperty [-DefaultProfile ] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` @@ -241,6 +241,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/StackHCI/StackHCI/help/Test-AzStackHciEdgeDevice.md b/src/StackHCI/StackHCI/help/Test-AzStackHciEdgeDevice.md index 931903b712d3..24cd2f16d7ac 100644 --- a/src/StackHCI/StackHCI/help/Test-AzStackHciEdgeDevice.md +++ b/src/StackHCI/StackHCI/help/Test-AzStackHciEdgeDevice.md @@ -16,27 +16,27 @@ A long-running resource action. ``` Test-AzStackHciEdgeDevice -Name -ResourceUri -EdgeDeviceId [-AdditionalInfo ] [-DefaultProfile ] [-AsJob] [-NoWait] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### Validate ``` Test-AzStackHciEdgeDevice -Name -ResourceUri -ValidateRequest - [-DefaultProfile ] [-AsJob] [-NoWait] [-WhatIf] [-Confirm] + [-DefaultProfile ] [-AsJob] [-NoWait] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### ValidateViaIdentityExpanded ``` Test-AzStackHciEdgeDevice -InputObject -EdgeDeviceId [-AdditionalInfo ] - [-DefaultProfile ] [-AsJob] [-NoWait] [-WhatIf] [-Confirm] + [-DefaultProfile ] [-AsJob] [-NoWait] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### ValidateViaIdentity ``` Test-AzStackHciEdgeDevice -InputObject -ValidateRequest - [-DefaultProfile ] [-AsJob] [-NoWait] [-WhatIf] [-Confirm] + [-DefaultProfile ] [-AsJob] [-NoWait] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` @@ -169,6 +169,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceUri The fully qualified Azure Resource manager identifier of the resource. diff --git a/src/StackHCI/StackHCI/help/Unregister-AzStackHCI.md b/src/StackHCI/StackHCI/help/Unregister-AzStackHCI.md index 270c63c1fcc3..bc6a6a1ad184 100644 --- a/src/StackHCI/StackHCI/help/Unregister-AzStackHCI.md +++ b/src/StackHCI/StackHCI/help/Unregister-AzStackHCI.md @@ -18,7 +18,7 @@ Unregister-AzStackHCI [[-SubscriptionId] ] [[-ResourceName] ] [[ [[-ResourceGroupName] ] [[-ArmAccessToken] ] [[-AccountId] ] [[-EnvironmentName] ] [[-Region] ] [[-ComputerName] ] [-UseDeviceAuthentication] [-DisableOnlyAzureArcServer] [-IsWAC] [[-Credential] ] [-Force] - [-WhatIf] [-Confirm] [] + [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -197,6 +197,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -Region Specifies the Region the resource is created in Azure. diff --git a/src/StackHCI/StackHCI/help/Update-AzStackHciCluster.md b/src/StackHCI/StackHCI/help/Update-AzStackHciCluster.md index 063ae4300949..34adf45f2eef 100644 --- a/src/StackHCI/StackHCI/help/Update-AzStackHciCluster.md +++ b/src/StackHCI/StackHCI/help/Update-AzStackHciCluster.md @@ -19,7 +19,7 @@ Update-AzStackHciCluster -Name -ResourceGroupName [-Subscripti [-DesiredPropertyDiagnosticLevel ] [-DesiredPropertyWindowsServerSubscription ] [-IdentityType ] [-IdentityUserAssignedIdentity ] [-Tag ] - [-DefaultProfile ] [-WhatIf] [-Confirm] [] + [-DefaultProfile ] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ### UpdateViaIdentityExpanded @@ -28,7 +28,7 @@ Update-AzStackHciCluster -InputObject [-AadTenantId [-CloudManagementEndpoint ] [-DesiredPropertyDiagnosticLevel ] [-DesiredPropertyWindowsServerSubscription ] [-IdentityType ] [-IdentityUserAssignedIdentity ] [-Tag ] - [-DefaultProfile ] [-WhatIf] [-Confirm] [] + [-DefaultProfile ] [-ProgressAction ] [-WhatIf] [-Confirm] [] ``` ## DESCRIPTION @@ -190,6 +190,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -ProgressAction +{{ Fill ProgressAction Description }} + +```yaml +Type: System.Management.Automation.ActionPreference +Parameter Sets: (All) +Aliases: proga + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -ResourceGroupName The name of the resource group. The name is case insensitive. diff --git a/src/Storage/LiveTests/Storage.Management/BlobTests.ps1 b/src/Storage/LiveTests/Storage.Management/BlobTests.ps1 index 5dda1aee99f5..ad87ab7782ce 100644 --- a/src/Storage/LiveTests/Storage.Management/BlobTests.ps1 +++ b/src/Storage/LiveTests/Storage.Management/BlobTests.ps1 @@ -10,8 +10,10 @@ Invoke-LiveTestScenario -Name "Blob basics" -Description "Test blob basic operat $ContentMD5 = "i727sP7HigloQDsqadNLHw==" $testfile512path = "$PSScriptRoot\TestFiles\testfile512" - $account = New-AzStorageAccount -ResourceGroupName $rgName -Name $storageAccountName -Location $location -SkuName Standard_GRS -AllowBlobPublicAccess $true + $account = New-AzStorageAccount -ResourceGroupName $rgName -Name $storageAccountName -Location $location -SkuName Standard_GRS -AllowSharedKeyAccess $true -Tag @{"Az.Sec.DisableAllowSharedKeyAccess::Skip" = "For Powershell test."} $ctx = $account.Context + $ctx1 = New-AzStorageContext -StorageAccountName $storageAccountName -StorageAccountKey (Get-AzStorageAccountKey -ResourceGroupName $rgName -Name $storageAccountName)[0].Value + $container = New-AzStorageContainer -Name $containerName -Context $ctx $containerSAS = New-AzStorageContainerSASToken -Name $containerName -Permission radwl -ExpiryTime 5000-01-01 -Context $ctx $sasCtx = New-AzStorageContext -SasToken $containerSAS -StorageAccountName $storageAccountName @@ -22,9 +24,6 @@ Invoke-LiveTestScenario -Name "Blob basics" -Description "Test blob basic operat $accessPolicy = Get-AzStorageContainerStoredAccessPolicy -Container $containerName -Context $ctx Assert-AreNotEqual $null $accessPolicy Assert-AreEqual $accessPolicyName $accessPolicy.Policy - Set-AzStorageContainerAcl -Name $containerName -Permission Blob -Context $ctx - $container = Get-AzStorageContainer -Name $containerName -Context $ctx - Assert-AreEqual "Blob" $container.Permission.PublicAccess # upload $blobName = New-LiveTestResourceName @@ -50,13 +49,13 @@ Invoke-LiveTestScenario -Name "Blob basics" -Description "Test blob basic operat $b.FetchAttributes() Assert-AreEqual "Hot" $b.BlobProperties.AccessTier - $b2 = Set-AzStorageBlobContent -File $testfile512path -Container $containerName -Blob $blobName2 -Force -Context $ctx + $b2 = Set-AzStorageBlobContent -File $testfile512path -Container $containerName -Blob $blobName2 -Force -Context $ctx1 $blobs = Get-AzStorageBlob -Container $containerName -Context $ctx Assert-AreEqual 2 $blobs.Count $b3 = Set-AzStorageBlobContent -File $testfile512path -Container $containerName -Blob $blobName3 -Force -Context $sasCtx $b2.BlobBaseClient.CreateSnapshot() - $blobs = Get-AzStorageBlob -Container $containerName -Prefix "blob3" -Context $ctx + $blobs = Get-AzStorageBlob -Container $containerName -Prefix "blob3" -Context $ctx1 Assert-AreEqual 1 $blobs.Count Assert-AreEqual $blobName3 $blobs[0].Name @@ -66,7 +65,7 @@ Invoke-LiveTestScenario -Name "Blob basics" -Description "Test blob basic operat Assert-AreEqual $blobName2 $blob.Name Assert-AreEqual $snapshotblob.SnapshotTime $blob.SnapshotTime - $blob = Set-AzStorageBlobContent -File $testfile512path -Container $containerName -Blob $blobName3 -Tag @{"Tag1" = "Value2"; "Tag2" = "Value2" } -Context $ctx -Force + $blob = Set-AzStorageBlobContent -File $testfile512path -Container $containerName -Blob $blobName3 -Tag @{"Tag1" = "Value2"; "Tag2" = "Value2" } -Context $ctx1 -Force $blob = Get-AzStorageBlob -Blob $blobName3 -Container $containerName -IncludeTag -Context $ctx Assert-AreEqual $blobName3 $blob.Name Assert-AreEqual 2 $blob.TagCount @@ -77,7 +76,7 @@ Invoke-LiveTestScenario -Name "Blob basics" -Description "Test blob basic operat $blob = Set-AzStorageBlobContent -File $testfile512path -Container $containerName -Blob $blobName3 -Context $sasctx -Force $blobs = Get-AzStorageBlob -Container $containerName -Context $ctx -IncludeVersion $versionBlob = $blobs | ? { $_.VersionId -ne $null } | Select-Object -First 1 - $blob = Get-AzStorageBlob -Container $containerName -Blob $blobName3 -VersionId $versionBlob.VersionId -Context $ctx + $blob = Get-AzStorageBlob -Container $containerName -Blob $blobName3 -VersionId $versionBlob.VersionId -Context $ctx1 Assert-AreEqual $blobName3 $blob.Name Assert-AreEqual $versionBlob.VersionId $blob.VersionId @@ -85,13 +84,8 @@ Invoke-LiveTestScenario -Name "Blob basics" -Description "Test blob basic operat $blobs = Get-AzStorageBlob -Container $containerName -Context $ctx Assert-AreEqual 2 $blobs.Count - $container = Get-AzStorageContainer -Name $containerName -Context $ctx - $containerProperties = $container.BlobContainerClient.GetProperties().Value - Assert-AreEqual $container.BlobContainerProperties.ETag $containerProperties.ETag - Set-AzStorageContainerAcl -Name $containerName -Permission Blob -Context $ctx + $container = Get-AzStorageContainer -Name $containerName -Context $ctx1 $containerProperties = $container.BlobContainerClient.GetProperties().Value - Assert-AreNotEqual $container.BlobContainerProperties.ETag $containerProperties.ETag - $container.FetchAttributes() Assert-AreEqual $container.BlobContainerProperties.ETag $containerProperties.ETag # sync copy diff --git a/src/Storage/LiveTests/Storage.Management/FileTests.ps1 b/src/Storage/LiveTests/Storage.Management/FileTests.ps1 new file mode 100644 index 000000000000..ca2abc168c85 --- /dev/null +++ b/src/Storage/LiveTests/Storage.Management/FileTests.ps1 @@ -0,0 +1,149 @@ +Invoke-LiveTestScenario -Name "File basics" -Description "Test File basic operation" -ScenarioScript ` +{ + param ($rg) + + $rgName = $rg.ResourceGroupName + $storageAccountName = New-LiveTestStorageAccountName + $shareName = New-LiveTestResourceName + $testfile512path = "$PSScriptRoot\TestFiles\testfile512" + $localDestFile = "$PSScriptRoot\TestFiles\dest" + $location = $rg.Location + $account = New-AzStorageAccount -ResourceGroupName $rgName -Name $storageAccountName -Location $location -SkuName Standard_GRS -AllowSharedKeyAccess $true -Tag @{"Az.Sec.DisableAllowSharedKeyAccess::Skip" = "For Powershell test."} + $ctx = $account.Context + $ctx1 = New-AzStorageContext -StorageAccountName $storageAccountName -StorageAccountKey (Get-AzStorageAccountKey -ResourceGroupName $rgName -Name $storageAccountName)[0].Value + + $objectName1 = "filetest1.txt." + $objectName2 = "filetest2.txt" + + #Create a file share + New-AzStorageShare $shareName -Context $ctx + $Share = Get-AzStorageShare -Name $shareName -Context $ctx + Assert-AreEqual $Share.Count 1 + Assert-AreEqual $Share[0].Name $shareName + + # upload file + $t = Set-AzStorageFileContent -source $testfile512path -ShareName $shareName -Path $objectName1 -Force -Context $ctx -asjob + $t | wait-job + Assert-AreEqual $t.State "Completed" + Assert-AreEqual $t.Error $null + + # upload/remove file/dir with -DisAllowTrailingDot + $dirName1WithTrailingDot = "testdir1.." + $dirName1WithOutTrailingDot = "testdir1" + $objectPathWithoutTrailingDot = "testdir1/filetest1.txt" + New-AzStorageDirectory -ShareName $shareName -Path $dirName1WithTrailingDot -Context $ctx1 -DisAllowTrailingDot + $file11 = Set-AzStorageFileContent -source $testfile512path -ShareName $shareName -Path "$($dirName1WithTrailingDot)/$($objectName1)" -Force -Context $ctx1 -DisAllowTrailingDot + $file = Get-AzStorageFile -ShareName $shareName -Path $objectPathWithoutTrailingDot -Context $ctx1 -DisAllowTrailingDot + Assert-AreEqual $file.Count 1 + Assert-AreEqual $file[0].ShareFileClient.Path $objectPathWithoutTrailingDot + Remove-AzStorageFile -ShareName $shareName -Path "$($dirName1WithTrailingDot)/$($objectName1)" -Context $ctx1 -DisAllowTrailingDot + Remove-AzStorageDirectory -ShareName $shareName -Path $dirName1WithTrailingDot -Context $ctx1 -DisAllowTrailingDot + + # list file + $file = Get-AzStorageFile -ShareName $shareName -Context $ctx + Assert-AreEqual $file.Count 1 + Assert-AreEqual $file[0].Name $objectName1 + Assert-NotNull $file[0].ListFileProperties.Properties.ETag + + if ($Env:OS -eq "Windows_NT") + { + Set-AzStorageFileContent -source $testfile512path -ShareName $shareName -Path $objectName1 -PreserveSMBAttribute -Force -Context $ctx + } + else + { + Set-AzStorageFileContent -source $testfile512path -ShareName $shareName -Path $objectName1 -Force -Context $ctx + } + $file = Get-AzStorageFile -ShareName $shareName -Context $ctx + Assert-AreEqual $file.Count 1 + Assert-AreEqual $file[0].Name $objectName1 + Assert-NotNull $file[0].ListFileProperties.Properties.ETag + if ($Env:OS -eq "Windows_NT") + { + $localFileProperties = Get-ItemProperty $testfile512path + Assert-AreEqual $localFileProperties.CreationTime.ToUniversalTime().Ticks $file[0].ListFileProperties.Properties.CreatedOn.ToUniversalTime().Ticks + Assert-AreEqual $localFileProperties.LastWriteTime.ToUniversalTime().Ticks $file[0].ListFileProperties.Properties.LastWrittenOn.ToUniversalTime().Ticks + Assert-AreEqual $localFileProperties.Attributes.ToString() $file[0].ListFileProperties.FileAttributes.ToString() + } + + Start-AzStorageFileCopy -SrcShareName $shareName -SrcFilePath $objectName1 -DestShareName $shareName -DestFilePath $objectName2 -Force -Context $ctx -DestContext $ctx + Get-AzStorageFileCopyState -ShareName $shareName -FilePath $objectName2 -Context $ctx -WaitForComplete + $file = Get-AzStorageFile -ShareName $shareName -Context $ctx + Assert-AreEqual $file.Count 2 + Assert-AreEqual $file[0].Name $objectName1 + Assert-AreEqual $file[1].Name $objectName2 + + $t = Get-AzStorageFileContent -ShareName $shareName -Path $objectName1 -Destination $localDestFile -Force -Context $ctx -asjob + $t | wait-job + Assert-AreEqual $t.State "Completed" + Assert-AreEqual $t.Error $null + Assert-AreEqual (Get-FileHash -Path $localDestFile -Algorithm MD5).Hash (Get-FileHash -Path $testfile512path -Algorithm MD5).Hash + + if ($Env:OS -eq "Windows_NT") + { + Get-AzStorageFileContent -ShareName $shareName -Path $objectName1 -Destination $localDestFile -PreserveSMBAttribute -Force -Context $ctx1 + } + else + { + Get-AzStorageFileContent -ShareName $shareName -Path $objectName1 -Destination $localDestFile -Force -Context $ctx + } + Assert-AreEqual (Get-FileHash -Path $localDestFile -Algorithm MD5).Hash (Get-FileHash -Path $testfile512path -Algorithm MD5).Hash + if ($Env:OS -eq "Windows_NT") + { + $file = Get-AzStorageFile -ShareName $shareName -Path $objectName1 -Context $ctx1 + $localFileProperties = Get-ItemProperty $testfile512path + Assert-AreEqual $localFileProperties.CreationTime.ToUniversalTime().Ticks $file[0].FileProperties.SmbProperties.FileCreatedOn.ToUniversalTime().Ticks + Assert-AreEqual $localFileProperties.LastWriteTime.ToUniversalTime().Ticks $file[0].FileProperties.SmbProperties.FileLastWrittenOn.ToUniversalTime().Ticks + Assert-AreEqual $localFileProperties.Attributes.ToString() $file[0].FileProperties.SmbProperties.FileAttributes.ToString() + } + + $fileName1 = "new" + $objectName1 + $file = Get-AzStorageFile -ShareName $shareName -Path $objectName1 -Context $ctx + + $file2 = Rename-AzStorageFile -ShareName $shareName -SourcePath $objectName1 -DestinationPath $fileName1 -Context $ctx + Assert-AreEqual $file2.Name $fileName1 + Assert-AreEqual $file.FileProperties.ContentType $file2.FileProperties.ContentType + Assert-AreEqual $file.FileProperties.ContentLength $file2.FileProperties.ContentLength + + $file3 = $file2 | Rename-AzStorageFile -DestinationPath $fileName1 -Context $ctx1 -Force + Assert-AreEqual $file3.Name $fileName1 + Assert-AreEqual $file2.FileProperties.ContentType $file3.FileProperties.ContentType + Assert-AreEqual $file2.FileProperties.ContentLength $file3.FileProperties.ContentLength + + Remove-AzStorageFile -ShareName $shareName -Path $fileName1 -Context $ctx + $file = Get-AzStorageFile -ShareName $shareName -Context $ctx + Assert-AreEqual $file.Count 1 + Assert-AreEqual $file[0].Name $objectName2 + + $dirName = "filetestdir" + New-AzStorageDirectory -ShareName $shareName -Path $dirName -Context $ctx + $file = Get-AzStorageShare -Name $shareName -Context $ctx1 | Get-AzStorageFile -ExcludeExtendedInfo + Assert-AreEqual $file.Count 2 + Assert-AreEqual $file[0].Name $dirName + Assert-AreEqual $file[0].GetType().Name "AzureStorageFileDirectory" + Assert-Null $file[0].ListFileProperties.Properties.ETag + Assert-AreEqual $file[1].Name $objectName2 + Assert-AreEqual $file[1].GetType().Name "AzureStorageFile" + Assert-Null $file[1].ListFileProperties.Properties.ETag + + $newDir = "new" + $dirName + ".." + $dir = Get-AzStorageFile -ShareName $shareName -Path $dirName -Context $ctx + $dir2 = Rename-AzStorageDirectory -ShareName $shareName -SourcePath $dirName -DestinationPath $newDir -Context $ctx1 + Assert-AreEqual $newDir $dir2.Name + Assert-AreEqual $dir.ListFileProperties.IsDirectory $dir2.ListFileProperties.IsDirectory + Assert-AreEqual $dir.ListFileProperties.FileAttributes $dir2.ListFileProperties.FileAttributes + + $newDir2 = "new2" + $dirName + $dir3 = $dir2 | Rename-AzStorageDirectory -DestinationPath $newDir2 -Context $ctx1 + Assert-AreEqual $newDir2 $dir3.Name + Assert-AreEqual $dir2.ListFileProperties.IsDirectory $dir3.ListFileProperties.IsDirectory + Assert-AreEqual $dir2.ListFileProperties.FileAttributes $dir3.ListFileProperties.FileAttributes + + $dir3 | Remove-AzStorageDirectory + $file = Get-AzStorageFile -ShareName $shareName -Context $ctx + Assert-AreEqual $file.Count 1 + Assert-AreEqual $file[0].Name $objectName2 + Assert-AreEqual $file[0].GetType().Name "AzureStorageFile" + + # Clean Storage Account + Remove-AzStorageShare -Name $shareName -Force -Context $ctx +} \ No newline at end of file diff --git a/src/Storage/LiveTests/Storage.Management/QueueTests.ps1 b/src/Storage/LiveTests/Storage.Management/QueueTests.ps1 index 1182aef9317b..75ee2eacb4d5 100644 --- a/src/Storage/LiveTests/Storage.Management/QueueTests.ps1 +++ b/src/Storage/LiveTests/Storage.Management/QueueTests.ps1 @@ -7,8 +7,9 @@ Invoke-LiveTestScenario -Name "Queue basics" -Description "Test queue basic oper $queueName = New-LiveTestResourceName $queueName2 = New-LiveTestResourceName $location = $rg.Location - $account = New-AzStorageAccount -ResourceGroupName $rgName -Name $storageAccountName -Location $location -SkuName Standard_GRS + $account = New-AzStorageAccount -ResourceGroupName $rgName -Name $storageAccountName -Location $location -SkuName Standard_GRS -AllowSharedKeyAccess $true -Tag @{"Az.Sec.DisableAllowSharedKeyAccess::Skip" = "For Powershell test."} $ctx = $account.Context + $ctx1 = New-AzStorageContext -StorageAccountName $storageAccountName -StorageAccountKey (Get-AzStorageAccountKey -ResourceGroupName $rgName -Name $storageAccountName)[0].Value $q = New-AzStorageQueue -Name $queueName -Context $ctx Assert-AreEqual $queueName $q.Name @@ -17,8 +18,8 @@ Invoke-LiveTestScenario -Name "Queue basics" -Description "Test queue basic oper Assert-AreEqual 0 $q.ApproximateMessageCount Assert-AreEqual 0 $q.QueueProperties.ApproximateMessagesCount - $q = New-AzStorageQueue -Name $queueName2 -Context $ctx - $qs = Get-AzStorageQueue -Context $ctx + $q = New-AzStorageQueue -Name $queueName2 -Context $ctx1 + $qs = Get-AzStorageQueue -Context $ctx1 Assert-AreEqual 2 $qs.Count $sas = New-AzStorageAccountSASToken -Service Queue -ResourceType Container,Object,Service -Permission rwdl -ExpiryTime 3000-01-01 -Context $ctx @@ -26,7 +27,7 @@ Invoke-LiveTestScenario -Name "Queue basics" -Description "Test queue basic oper $qs = Get-AzStorageQueue -Context $ctxaccountsas Assert-AreEqual 2 $qs.Count - $sas = New-AzStorageQueueSASToken -Name $queueName -Context $ctx -Permission ruap + $sas = New-AzStorageQueueSASToken -Name $queueName -Context $ctx1 -Permission ruap $sasctx = New-AzStorageContext -StorageAccountName $storageAccountName -SasToken $sas $q = Get-AzStorageQueue -Name $queueName -Context $sasctx Assert-AreEqual $queueName $q.Name @@ -53,10 +54,10 @@ Invoke-LiveTestScenario -Name "Queue basics" -Description "Test queue basic oper Assert-Null $p.StartTime Assert-AreEqual "rau" $p.Permissions - $p = New-AzStorageQueueStoredAccessPolicy -Queue $queueName -Policy $policyName2 -Permission ruap -Context $ctx + $p = New-AzStorageQueueStoredAccessPolicy -Queue $queueName -Policy $policyName2 -Permission ruap -Context $ctx1 $p = Get-AzStorageQueueStoredAccessPolicy -Queue $queueName -Context $ctx Assert-AreEqual 2 $p.Count - $p = Get-AzStorageQueueStoredAccessPolicy -Queue $queueName -Policy $policyName1 -Context $ctx + $p = Get-AzStorageQueueStoredAccessPolicy -Queue $queueName -Policy $policyName1 -Context $ctx1 Assert-AreEqual $policyName1 $p.Policy Remove-AzStorageQueueStoredAccessPolicy -Queue $queueName -Policy $policyName1 -Context $ctx diff --git a/src/Storage/LiveTests/Storage.Management/TableTests.ps1 b/src/Storage/LiveTests/Storage.Management/TableTests.ps1 new file mode 100644 index 000000000000..49f162029a21 --- /dev/null +++ b/src/Storage/LiveTests/Storage.Management/TableTests.ps1 @@ -0,0 +1,57 @@ +Invoke-LiveTestScenario -Name "Table basics" -Description "Test Table basic operation" -ScenarioScript ` +{ + param ($rg) + + $rgName = $rg.ResourceGroupName + $storageAccountName = New-LiveTestStorageAccountName + $tableName = New-LiveTestResourceName + $tableName2 = New-LiveTestResourceName + $location = $rg.Location + $account = New-AzStorageAccount -ResourceGroupName $rgName -Name $storageAccountName -Location $location -SkuName Standard_GRS -AllowSharedKeyAccess $true -Tag @{"Az.Sec.DisableAllowSharedKeyAccess::Skip" = "For Powershell test."} + $ctx = $account.Context + $ctx1 = New-AzStorageContext -StorageAccountName $storageAccountName -StorageAccountKey (Get-AzStorageAccountKey -ResourceGroupName $rgName -Name $storageAccountName)[0].Value + + # Create Table + New-AzStorageTable -Name $tableName -Context $ctx + $table =Get-AzStorageTable -Name $tableName -Context $ctx + Assert-AreEqual $table.Count 1 + Assert-AreEqual $table[0].Name $tableName + New-AzStorageTable -Name $tableName2 -Context $ctx1 + $table2 =Get-AzStorageTable -Name $tableName2 -Context $ctx1 + Assert-AreEqual $table2.Count 1 + Assert-AreEqual $table2[0].Name $tableName2 + + #Test run Table query - Insert Entity + $partitionKey = "p123" + $rowKey = "row123" + $tableRow = [Azure.Data.Tables.TableEntity]::new($partitionKey, $rowKey) + $tableRow.Add("Name", "name1") + $tableRow.Add("ID", 4567) + $methodAddEntity = [Azure.Data.Tables.TableClient].GetMethods() | Where-Object Name -eq "AddEntity" + $methodAddEntity = $methodAddEntity.MakeGenericMethod([Azure.Data.Tables.TableEntity]) + $methodAddEntity.Invoke($table.TableClient, @([Azure.Data.Tables.TableEntity]$tableRow, $null)) + + # Create Table Object - which reference to exist Table with SAS + $tableSASUri = New-AzStorageTableSASToken -Name $tablename -Permission "raud" -ExpiryTime (([DateTime]::UtcNow.AddDays(10))) -FullUri -Context $ctx + $uri = [System.Uri]$tableSASUri + $sasTable = New-Object -TypeName Azure.Data.Tables.TableClient $uri + + #Get Entity + $methodGetEntity = [Azure.Data.Tables.TableClient].GetMethods() | Where-Object Name -eq "GetEntity" + $methodGetEntity = $methodGetEntity.MakeGenericMethod([Azure.Data.Tables.TableEntity]) + $entity = $methodGetEntity.Invoke($sasTable, @($partitionKey,$rowKey, $null, $null)).Value + Assert-AreEqual $partitionKey $entity["PartitionKey"] + Assert-AreEqual $rowKey $entity["RowKey"] + Assert-AreEqual "name1" $entity["Name"] + Assert-AreEqual 4567 $entity["ID"] + + # Get/Remove Table + $tableCount1 = (Get-AzStorageTable -Context $ctx).Count + Assert-AreEqual $tableCount1 2 + Remove-AzStorageTable -Name $tableName -Force -Context $ctx + $tableCount2 = (Get-AzStorageTable -Context $ctx1).Count + Assert-AreEqual $tableCount2 1 + $table2 | Remove-AzStorageTable -Force + $tableCount3 = (Get-AzStorageTable -Context $ctx1).Count + Assert-AreEqual $tableCount3 0 +} \ No newline at end of file diff --git a/src/Storage/LiveTests/Storage.Management/TestLiveScenarios.ps1 b/src/Storage/LiveTests/Storage.Management/TestLiveScenarios.ps1 index cd737e3ec05b..f515c45214a1 100644 --- a/src/Storage/LiveTests/Storage.Management/TestLiveScenarios.ps1 +++ b/src/Storage/LiveTests/Storage.Management/TestLiveScenarios.ps1 @@ -36,4 +36,6 @@ Invoke-LiveTestScenario -Name "Removes a Storage account" -Description "Test rem } & "$PSScriptRoot\QueueTests.ps1" -& "$PSScriptRoot\BlobTests.ps1" \ No newline at end of file +& "$PSScriptRoot\BlobTests.ps1" +& "$PSScriptRoot\TableTests.ps1" +& "$PSScriptRoot\FileTests.ps1" \ No newline at end of file diff --git a/src/Storage/Storage.Management.Test/ScenarioTests/StorageDataPlaneTests.ps1 b/src/Storage/Storage.Management.Test/ScenarioTests/StorageDataPlaneTests.ps1 index df4772538539..74d5730a8714 100644 --- a/src/Storage/Storage.Management.Test/ScenarioTests/StorageDataPlaneTests.ps1 +++ b/src/Storage/Storage.Management.Test/ScenarioTests/StorageDataPlaneTests.ps1 @@ -35,6 +35,8 @@ function Test-File $storageAccountKeyValue = $(Get-AzStorageAccountKey -ResourceGroupName $ResourceGroupName -Name $StorageAccountName)[0].Value $storageContext = New-AzStorageContext -StorageAccountName $StorageAccountName -StorageAccountKey $storageAccountKeyValue + $storageContext2 = (Get-AzStorageAccount -ResourceGroupName $ResourceGroupName -Name $StorageAccountName).Context + $localSrcFile = "localsrcfiletestfile.psd1" #The file need exist before test, and should be 512 bytes aligned New-Item $localSrcFile -ItemType File -Force $localDestFile = "localdestfiletestfile1.txt" @@ -59,13 +61,13 @@ function Test-File $dirName1WithTrailingDot = "testdir1.." $dirName1WithOutTrailingDot = "testdir1" $objectPathWithoutTrailingDot = "testdir1/filetest1.txt" - New-AzStorageDirectory -ShareName $shareName -Path $dirName1WithTrailingDot -Context $storageContext -DisAllowTrailingDot - $file11 = Set-AzStorageFileContent -source $localSrcFile -ShareName $shareName -Path "$($dirName1WithTrailingDot)/$($objectName1)" -Force -Context $storageContext -DisAllowTrailingDot - $file = Get-AzStorageFile -ShareName $shareName -Path $objectPathWithoutTrailingDot -Context $storageContext -DisAllowTrailingDot + New-AzStorageDirectory -ShareName $shareName -Path $dirName1WithTrailingDot -Context $storageContext2 -DisAllowTrailingDot + $file11 = Set-AzStorageFileContent -source $localSrcFile -ShareName $shareName -Path "$($dirName1WithTrailingDot)/$($objectName1)" -Force -Context $storageContext2 -DisAllowTrailingDot + $file = Get-AzStorageFile -ShareName $shareName -Path $objectPathWithoutTrailingDot -Context $storageContext2 -DisAllowTrailingDot Assert-AreEqual $file.Count 1 Assert-AreEqual $file[0].ShareFileClient.Path $objectPathWithoutTrailingDot - Remove-AzStorageFile -ShareName $shareName -Path "$($dirName1WithTrailingDot)/$($objectName1)" -Context $storageContext -DisAllowTrailingDot - Remove-AzStorageDirectory -ShareName $shareName -Path $dirName1WithTrailingDot -Context $storageContext -DisAllowTrailingDot + Remove-AzStorageFile -ShareName $shareName -Path "$($dirName1WithTrailingDot)/$($objectName1)" -Context $storageContext2 -DisAllowTrailingDot + Remove-AzStorageDirectory -ShareName $shareName -Path $dirName1WithTrailingDot -Context $storageContext2 -DisAllowTrailingDot # list file $file = Get-AzStorageFile -ShareName $shareName -Context $storageContext @@ -198,6 +200,7 @@ function Test-Blob ) New-TestResourceGroupAndStorageAccount -ResourceGroupName $ResourceGroupName -StorageAccountName $StorageAccountName + Set-AzStorageAccount -ResourceGroupName $ResourceGroupName -StorageAccountName $StorageAccountName -AllowBlobPublicAccess $true try{ $location = Get-ProviderLocation ResourceManagement @@ -211,9 +214,8 @@ function Test-Blob $containerName = "blobtestcontainer" $storageAccountName2 = $storageAccountName + "2" - New-AzStorageAccount -Name $storageAccountName2 -ResourceGroupName $ResourceGroupName -Location $location -Type 'Standard_LRS' - $storageAccountKeyValue2 = $(Get-AzStorageAccountKey -ResourceGroupName $ResourceGroupName -Name $StorageAccountName2)[0].Value - $storageContext2 = New-AzStorageContext -StorageAccountName $StorageAccountName2 -StorageAccountKey $storageAccountKeyValue2 + New-AzStorageAccount -Name $storageAccountName2 -ResourceGroupName $ResourceGroupName -Location $location -Type 'Standard_LRS' + $storageContext2 = (Get-AzStorageAccount -ResourceGroupName $ResourceGroupName -Name $StorageAccountName2).Context $containerName3 = "blobtestcontainer2" New-AzStorageContainer $containerName3 -Context $storageContext New-AzStorageContainer $containerName3 -Context $storageContext2 @@ -435,6 +437,8 @@ function Test-Blob Remove-AzStorageContainer -Name $containerName -Force -Context $storageContext Remove-AzStorageContainer -Name $containerName3 -Force -Context $storageContext Remove-AzStorageContainer -Name $containerName3 -Force -Context $storageContext2 + + Set-AzStorageAccount -ResourceGroupName $ResourceGroupName -StorageAccountName $StorageAccountName -AllowBlobPublicAccess $false } finally { @@ -464,6 +468,8 @@ function Test-Queue $storageAccountKeyValue = $(Get-AzStorageAccountKey -ResourceGroupName $ResourceGroupName -Name $StorageAccountName)[0].Value $storageContext = New-AzStorageContext -StorageAccountName $StorageAccountName -StorageAccountKey $storageAccountKeyValue + $storageContext2 = (Get-AzStorageAccount -ResourceGroupName $ResourceGroupName -Name $StorageAccountName).Context + $queueName = "queue-test" New-AzStorageQueue -Name $queueName -Context $storageContext $queue = Get-AzStorageQueue -Name $queueName -Context $storageContext @@ -473,7 +479,7 @@ function Test-Queue $queueMessage = "This is message 1" $queue.QueueClient.SendMessage($queueMessage) - $queueCount1 = (Get-AzStorageQueue -Context $storageContext).Count + $queueCount1 = (Get-AzStorageQueue -Context $storageContext2).Count Remove-AzStorageQueue -Name $queueName -Force -Context $storageContext $queue2 = Get-AzStorageQueue -Context $storageContext # modified, it did not assign to anything if ($null -eq $queue2) { # modified, PS guidelines require null on the left side @@ -511,11 +517,13 @@ function Test-Table { $storageAccountKeyValue = $(Get-AzStorageAccountKey -ResourceGroupName $ResourceGroupName -Name $StorageAccountName)[0].Value $storageContext = New-AzStorageContext -StorageAccountName $StorageAccountName -StorageAccountKey $storageAccountKeyValue + + $storageContext2 = (Get-AzStorageAccount -ResourceGroupName $ResourceGroupName -Name $StorageAccountName).Context # Create Table $tableName = "tabletest" New-AzStorageTable -Name $tableName -Context $storageContext - $table =Get-AzStorageTable -Name $tableName -Context $storageContext + $table =Get-AzStorageTable -Name $tableName -Context $storageContext2 Assert-AreEqual $table.Count 1 Assert-AreEqual $table[0].Name $tableName @@ -586,6 +594,8 @@ function Test-BlobFileCopy { $storageAccountKeyValue = $(Get-AzStorageAccountKey -ResourceGroupName $ResourceGroupName -Name $StorageAccountName)[0].Value $storageContext = New-AzStorageContext -StorageAccountName $StorageAccountName -StorageAccountKey $storageAccountKeyValue + + $storageContext2 = (Get-AzStorageAccount -ResourceGroupName $ResourceGroupName -Name $StorageAccountName).Context $localSrcFile = "localsrcblobfilecopytestfile.psd1" #The file need exist before test, and should be 512 bytes aligned New-Item $localSrcFile -ItemType File -Force @@ -599,8 +609,8 @@ function Test-BlobFileCopy $ContentMD5 = "i727sP7HigloQDsqadNLHw==" $containerName = "blobfilecopytestcontainer" - New-AzStorageContainer $containerName -Context $storageContext - Set-AzStorageBlobContent -File $localSrcFile -Container $containerName -Blob $objectName1 -Force -Properties @{"ContentType" = $ContentType; "ContentMD5" = $ContentMD5} -Context $storageContext + New-AzStorageContainer $containerName -Context $storageContext2 + Set-AzStorageBlobContent -File $localSrcFile -Container $containerName -Blob $objectName1 -Force -Properties @{"ContentType" = $ContentType; "ContentMD5" = $ContentMD5} -Context $storageContext2 $blob = Get-AzStorageContainer -Name $containerName -Context $storageContext |Get-AzStorageBlob Assert-AreEqual $blob.Count 1 Assert-AreEqual $blob.Name $objectName1 @@ -627,8 +637,8 @@ function Test-BlobFileCopy Assert-AreEqual $blob.Count 1 Assert-AreEqual $blob[0].Name $objectName3 - Start-AzStorageFileCopy -SrcContainerName $containerName -SrcBlobName $objectName1 -DestShareName $shareName -DestFilePath $objectName3 -Force -Context $storageContext -DestContext $storageContext - Get-AzStorageFileCopyState -ShareName $shareName -FilePath $objectName3 -Context $storageContext + Start-AzStorageFileCopy -SrcContainerName $containerName -SrcBlobName $objectName1 -DestShareName $shareName -DestFilePath $objectName3 -Force -Context $storageContext2 -DestContext $storageContext2 + Get-AzStorageFileCopyState -ShareName $shareName -FilePath $objectName3 -Context $storageContext2 $file = Get-AzStorageFile -ShareName $shareName -Path $objectName3 -Context $storageContext Assert-AreEqual $file.Count 1 Assert-AreEqual $file[0].Name $objectName3 @@ -665,6 +675,8 @@ function Test-Common $storageAccountKeyValue = $(Get-AzStorageAccountKey -ResourceGroupName $ResourceGroupName -Name $StorageAccountName)[0].Value $storageContext = New-AzStorageContext -StorageAccountName $StorageAccountName -StorageAccountKey $storageAccountKeyValue + $storageContext2 = (Get-AzStorageAccount -ResourceGroupName $ResourceGroupName -Name $StorageAccountName).Context + # wait at most 120*5s=600s for the set sevice property updated on server. $retryTimes = 120 @@ -695,12 +707,12 @@ function Test-Common Assert-AreEqual $retentionDays $property.RetentionDays $MetricsLevel = "Service" - Set-AzStorageServiceMetricsProperty -ServiceType blob -Version $version -MetricsType Hour -RetentionDays $retentionDays -MetricsLevel $MetricsLevel -Context $storageContext + Set-AzStorageServiceMetricsProperty -ServiceType blob -Version $version -MetricsType Hour -RetentionDays $retentionDays -MetricsLevel $MetricsLevel -Context $storageContext2 $i = 0 $propertyUpdated = $false while (($i -lt $retryTimes ) -and ($propertyUpdated -eq $false)) { - $property = Get-AzStorageServiceMetricsProperty -ServiceType Blob -MetricsType Hour -Context $storageContext + $property = Get-AzStorageServiceMetricsProperty -ServiceType Blob -MetricsType Hour -Context $storageContext2 if (($property.RetentionDays -eq $retentionDays) -and ($property.Version -eq $version) -and ($property.MetricsLevel.ToString() -eq $MetricsLevel)) { $propertyUpdated = $true @@ -761,7 +773,7 @@ function Test-Common $i = $i + 5 } } - $cors = Get-AzStorageCORSRule -ServiceType blob -Context $storageContext + $cors = Get-AzStorageCORSRule -ServiceType blob -Context $storageContext2 Assert-AreEqual 0 $cors.Count # Table Service properties @@ -774,7 +786,7 @@ function Test-Common $propertyUpdated = $false while (($i -lt $retryTimes ) -and ($propertyUpdated -eq $false)) { - $property = Get-AzStorageServiceLoggingProperty -ServiceType table -Context $storageContext + $property = Get-AzStorageServiceLoggingProperty -ServiceType table -Context $storageContext2 if (($property.RetentionDays -eq $retentionDays) -and ($property.Version -eq $version) -and ($property.LoggingOperations -eq $LoggingOperations)) { $propertyUpdated = $true @@ -791,7 +803,7 @@ function Test-Common Assert-AreEqual $retentionDays $property.RetentionDays $MetricsLevel = "ServiceAndApi" - Set-AzStorageServiceMetricsProperty -ServiceType table -Version $version -MetricsType Minute -RetentionDays $retentionDays -MetricsLevel $MetricsLevel -Context $storageContext + Set-AzStorageServiceMetricsProperty -ServiceType table -Version $version -MetricsType Minute -RetentionDays $retentionDays -MetricsLevel $MetricsLevel -Context $storageContext2 $i = 0 $propertyUpdated = $false while (($i -lt $retryTimes ) -and ($propertyUpdated -eq $false)) @@ -832,7 +844,7 @@ function Test-Common $i = $i + 5 } } - $cors = Get-AzStorageCORSRule -ServiceType table -Context $storageContext + $cors = Get-AzStorageCORSRule -ServiceType table -Context $storageContext2 Assert-AreEqual 1 $cors.Count Remove-AzStorageCORSRule -ServiceType table -Context $storageContext @@ -882,6 +894,8 @@ function Test-DatalakeGen2 $storageAccountKeyValue = $(Get-AzStorageAccountKey -ResourceGroupName $ResourceGroupName -Name $StorageAccountName)[0].Value $storageContext = New-AzStorageContext -StorageAccountName $StorageAccountName -StorageAccountKey $storageAccountKeyValue + $storageContext2 = (Get-AzStorageAccount -ResourceGroupName $ResourceGroupName -Name $StorageAccountName).Context + $localSrcFile = "localsrcDatalakeGen2testfile.psd1" #The file need exist before test, and should be 512 bytes aligned New-Item $localSrcFile -ItemType File -Force $localDestFile = "localdestDatalakeGen2testfile.txt" @@ -906,7 +920,7 @@ function Test-DatalakeGen2 $dir1 = New-AzDataLakeGen2Item -Context $storageContext -FileSystem $filesystemName -Path $directoryPath1 -Directory -Permission rwxrwxrwx -Umask ---rwx--- -Property @{"ContentEncoding" = "UDF8"; "CacheControl" = "READ"} -Metadata @{"tag1" = "value1"; "tag2" = "value2" } Assert-AreEqual $dir1.Path $directoryPath1 Assert-AreEqual $dir1.Permissions.ToSymbolicPermissions() "rwx---rwx" - $dir2 = New-AzDataLakeGen2Item -Context $storageContext -FileSystem $filesystemName -Path $directoryPath2 -Directory -Permission r---wx-wT -Umask --x-wx--x + $dir2 = New-AzDataLakeGen2Item -Context $storageContext2 -FileSystem $filesystemName -Path $directoryPath2 -Directory -Permission r---wx-wT -Umask --x-wx--x Assert-AreEqual $dir2.Path $directoryPath2 Assert-AreEqual $dir2.Permissions.ToSymbolicPermissions() "r------wT" @@ -915,7 +929,7 @@ function Test-DatalakeGen2 $t | wait-job Assert-AreEqual $t.State "Completed" Assert-AreEqual $t.Error $null - $file2 = New-AzDataLakeGen2Item -Context $storageContext -FileSystem $filesystemName -Path $filePath2 -Source $localSrcFile -Permission rwxrwxrwx -Umask ---rwx--- -Property @{"ContentType" = $ContentType; "ContentMD5" = $ContentMD5} -Metadata @{"tag1" = "value1"; "tag2" = "value2" } + $file2 = New-AzDataLakeGen2Item -Context $storageContext2 -FileSystem $filesystemName -Path $filePath2 -Source $localSrcFile -Permission rwxrwxrwx -Umask ---rwx--- -Property @{"ContentType" = $ContentType; "ContentMD5" = $ContentMD5} -Metadata @{"tag1" = "value1"; "tag2" = "value2" } Assert-AreEqual $file2.Path $filePath2 Assert-AreEqual $file2.Properties.ContentType $ContentType Assert-AreEqual $file2.Properties.Metadata.Count 2 @@ -937,7 +951,7 @@ function Test-DatalakeGen2 -Permission rw-rw--wt ` -Owner '$superuser' ` -Group '$superuser' - $sas = New-AzDataLakeGen2SasToken -FileSystem $filesystemName -Path $filePath1 -Permission rw -Context $storageContext + $sas = New-AzDataLakeGen2SasToken -FileSystem $filesystemName -Path $filePath1 -Permission rw -Context $storageContext2 $ctxsas = New-AzStorageContext -StorageAccountName $StorageAccountName -SasToken $sas $file1 = Get-AzDataLakeGen2Item -Context $ctxsas -FileSystem $filesystemName -Path $filePath1 Assert-AreEqual $file1.Path $filePath1 @@ -954,7 +968,7 @@ function Test-DatalakeGen2 -Permission rw-rw--wx ` -Owner '$superuser' ` -Group '$superuser' - $dir1 = Get-AzDataLakeGen2Item -Context $storageContext -FileSystem $filesystemName -Path $directoryPath1 + $dir1 = Get-AzDataLakeGen2Item -Context $storageContext2 -FileSystem $filesystemName -Path $directoryPath1 Assert-AreEqual $dir1.Path $directoryPath1 Assert-AreEqual $dir1.Permissions.ToSymbolicPermissions() "rw-rw--wx" Assert-AreEqual $dir1.Properties.ContentEncoding $ContentEncoding @@ -967,12 +981,12 @@ function Test-DatalakeGen2 $items = Get-AzDataLakeGen2ChildItem -Context $storageContext -FileSystem $filesystemName -FetchPermission Assert-AreEqual $items.Count 2 Assert-NotNull $items[0].Permissions - $items = Get-AzDataLakeGen2ChildItem -Context $storageContext -FileSystem $filesystemName -Recurse + $items = Get-AzDataLakeGen2ChildItem -Context $storageContext2 -FileSystem $filesystemName -Recurse Assert-AreEqual $items.Count 4 Assert-AreEqual "rw-rw--wx" $items[0].Permissions.ToSymbolicPermissions() #download File - $t = Get-AzDataLakeGen2ItemContent -Context $storageContext -FileSystem $filesystemName -Path $filePath1 -Destination $localDestFile -AsJob -Force + $t = Get-AzDataLakeGen2ItemContent -Context $storageContext2 -FileSystem $filesystemName -Path $filePath1 -Destination $localDestFile -AsJob -Force $t | Wait-Job Assert-AreEqual $t.State "Completed" Assert-AreEqual $t.Error $null @@ -1003,7 +1017,7 @@ function Test-DatalakeGen2 Assert-AreEqual 0 $result.TotalFailureCount Assert-AreEqual 2 $result.TotalFilesSuccessfulCount Assert-AreEqual 3 $result.TotalDirectoriesSuccessfulCount - $result = Update-AzDataLakeGen2AclRecursive -Context $storageContext -FileSystem $filesystemName -Path $directoryPath1 -Acl $acl -BatchSize 2 -MaxBatchCount 2 + $result = Update-AzDataLakeGen2AclRecursive -Context $storageContext2 -FileSystem $filesystemName -Path $directoryPath1 -Acl $acl -BatchSize 2 -MaxBatchCount 2 Assert-Null $result.FailedEntries Assert-AreEqual 0 $result.TotalFailureCount Assert-AreEqual 1 $result.TotalFilesSuccessfulCount diff --git a/src/Terraform/Terraform/Az.Terraform.psd1 b/src/Terraform/Terraform/Az.Terraform.psd1 index 45c222b1fa2e..051353994479 100644 --- a/src/Terraform/Terraform/Az.Terraform.psd1 +++ b/src/Terraform/Terraform/Az.Terraform.psd1 @@ -30,7 +30,7 @@ CompanyName = 'Microsoft Corporation' Copyright = 'Microsoft Corporation. All rights reserved.' # Description of the functionality provided by this module -Description = 'Microsoft Azure PowerShell: {ModuleNamePlaceHolder} cmdlets' +Description = 'Microsoft Azure PowerShell - Azure Terraform cmdlets for Azure Resource Manager in Windows PowerShell and PowerShell Core.' # Minimum version of the PowerShell engine required by this module PowerShellVersion = '5.1' @@ -97,7 +97,7 @@ PrivateData = @{ PSData = @{ # Tags applied to this module. These help with module discovery in online galleries. - Tags = 'Azure', 'ResourceManager', 'ARM', 'PSModule', '{ModuleNamePlaceHolder}' + Tags = 'Azure', 'ResourceManager', 'ARM', 'PSModule', 'Terraform' # A URL to the license for this module. LicenseUri = 'https://aka.ms/azps-license' diff --git a/src/Terraform/Terraform/ChangeLog.md b/src/Terraform/Terraform/ChangeLog.md index 1780486ecdd4..f5fbaa2516bc 100644 --- a/src/Terraform/Terraform/ChangeLog.md +++ b/src/Terraform/Terraform/ChangeLog.md @@ -18,6 +18,7 @@ - Additional information about change #1 --> ## Upcoming Release +* Fixed descrption for this module ## Version 0.1.0 * First preview release for module Az.Terraform diff --git a/tools/Az/Az.psd1 b/tools/Az/Az.psd1 index a9a371c1e231..35227dba1c26 100644 --- a/tools/Az/Az.psd1 +++ b/tools/Az/Az.psd1 @@ -120,7 +120,7 @@ RequiredModules = @(@{ModuleName = 'Az.Accounts'; ModuleVersion = '3.0.4'; }, @{ModuleName = 'Az.PrivateDns'; RequiredVersion = '1.0.5'; }, @{ModuleName = 'Az.RecoveryServices'; RequiredVersion = '7.2.0'; }, @{ModuleName = 'Az.RedisCache'; RequiredVersion = '1.10.0'; }, - @{ModuleName = 'Az.RedisEnterpriseCache'; RequiredVersion = '1.3.0'; }, + @{ModuleName = 'Az.RedisEnterpriseCache'; RequiredVersion = '1.2.1'; }, @{ModuleName = 'Az.Relay'; RequiredVersion = '2.0.1'; }, @{ModuleName = 'Az.ResourceGraph'; RequiredVersion = '1.0.0'; }, @{ModuleName = 'Az.ResourceMover'; RequiredVersion = '1.2.1'; }, @@ -262,14 +262,6 @@ Az.Network Az.RecoveryServices * Fixed bug for making RecoveryAzureStorageAccountId parameter optional in ''New-ASRReplicationProtectedItem'' cmdlet of H2A. -Az.RedisEnterpriseCache -* Added support for using Microsoft Entra token-based authentication. -* Added the new properties of Cluster: highAvailability and redundancyMode. -* Added new product SKUs. -* Added the new properties of Database: accessKeysAuthentication. -* Added Invoke-AzRedisEnterpriseCacheForceDatabaseLinkToReplicationGroup to force link geo replicated caches. -* Added Update-AzRedisEnterpriseCacheDatabaseDbRedisVersion to upgrade the redis database version directly. - Az.Resources * Added ''ResourceSelector'' and ''Override'' parameters to ''New/Update-AzPolicyAssignment''. * Added ''ResourceSelector'' parameter to ''New/Update-AzPolicyExemption''. diff --git a/tools/AzPreview/AzPreview.psd1 b/tools/AzPreview/AzPreview.psd1 index c1aca96d5946..df95026b81a1 100644 --- a/tools/AzPreview/AzPreview.psd1 +++ b/tools/AzPreview/AzPreview.psd1 @@ -194,7 +194,7 @@ RequiredModules = @(@{ModuleName = 'Az.Accounts'; ModuleVersion = '3.0.4'; }, @{ModuleName = 'Az.Quota'; RequiredVersion = '0.1.2'; }, @{ModuleName = 'Az.RecoveryServices'; RequiredVersion = '7.2.0'; }, @{ModuleName = 'Az.RedisCache'; RequiredVersion = '1.10.0'; }, - @{ModuleName = 'Az.RedisEnterpriseCache'; RequiredVersion = '1.3.0'; }, + @{ModuleName = 'Az.RedisEnterpriseCache'; RequiredVersion = '1.2.1'; }, @{ModuleName = 'Az.Relay'; RequiredVersion = '2.0.1'; }, @{ModuleName = 'Az.Reservations'; RequiredVersion = '0.13.0'; }, @{ModuleName = 'Az.ResourceGraph'; RequiredVersion = '1.0.0'; }, diff --git a/tools/AzPreview/ChangeLog.md b/tools/AzPreview/ChangeLog.md index 89e259804276..3ad2666d5e9e 100644 --- a/tools/AzPreview/ChangeLog.md +++ b/tools/AzPreview/ChangeLog.md @@ -100,14 +100,6 @@ #### Az.RecoveryServices 7.2.0 * Fixed bug for making RecoveryAzureStorageAccountId parameter optional in 'New-ASRReplicationProtectedItem' cmdlet of H2A. -#### Az.RedisEnterpriseCache 1.3.0 -* Added support for using Microsoft Entra token-based authentication. -* Added the new properties of Cluster: highAvailability and redundancyMode. -* Added new product SKUs. -* Added the new properties of Database: accessKeysAuthentication. -* Added Invoke-AzRedisEnterpriseCacheForceDatabaseLinkToReplicationGroup to force link geo replicated caches. -* Added Update-AzRedisEnterpriseCacheDatabaseDbRedisVersion to upgrade the redis database version directly. - #### Az.Resources 7.5.0 * Added 'ResourceSelector' and 'Override' parameters to 'New/Update-AzPolicyAssignment'. * Added 'ResourceSelector' parameter to 'New/Update-AzPolicyExemption'. diff --git a/tools/Docs/az-ps-latest.csv b/tools/Docs/az-ps-latest.csv index ee9d8f35d494..0779b8a1f616 100644 --- a/tools/Docs/az-ps-latest.csv +++ b/tools/Docs/az-ps-latest.csv @@ -140,7 +140,7 @@ pac138,[ps=true;customSource=https://azpspackage.blob.core.windows.net/docs-rele pac139,[ps=true;customSource=https://azpspackage.blob.core.windows.net/docs-release/Az.Quota.0.1.2.zip;sourceType=sa]Az.Quota,0.1.2 pac140,[ps=true;customSource=https://azpspackage.blob.core.windows.net/docs-release/Az.RecoveryServices.7.2.0.zip;sourceType=sa]Az.RecoveryServices,7.2.0 pac141,[ps=true;customSource=https://azpspackage.blob.core.windows.net/docs-release/Az.RedisCache.1.10.0.zip;sourceType=sa]Az.RedisCache,1.10.0 -pac142,[ps=true;customSource=https://azpspackage.blob.core.windows.net/docs-release/Az.RedisEnterpriseCache.1.3.0.zip;sourceType=sa]Az.RedisEnterpriseCache,1.3.0 +pac142,[ps=true;customSource=https://azpspackage.blob.core.windows.net/docs-release/Az.RedisEnterpriseCache.1.2.1.zip;sourceType=sa]Az.RedisEnterpriseCache,1.2.1 pac143,[ps=true;customSource=https://azpspackage.blob.core.windows.net/docs-release/Az.Relay.2.0.1.zip;sourceType=sa]Az.Relay,2.0.1 pac144,[ps=true;customSource=https://azpspackage.blob.core.windows.net/docs-release/Az.Reservations.0.13.0.zip;sourceType=sa]Az.Reservations,0.13.0 pac145,[ps=true;customSource=https://azpspackage.blob.core.windows.net/docs-release/Az.ResourceGraph.1.0.0.zip;sourceType=sa]Az.ResourceGraph,1.0.0 diff --git a/tools/TestFx/Live/DebugLocalLiveTestScenarios.ps1 b/tools/TestFx/Live/DebugLocalLiveTestScenarios.ps1 index c6ad08b80ff6..8848798854af 100644 --- a/tools/TestFx/Live/DebugLocalLiveTestScenarios.ps1 +++ b/tools/TestFx/Live/DebugLocalLiveTestScenarios.ps1 @@ -40,7 +40,7 @@ function InvokeLocalLiveTestScenarios { ) $srcDir = Join-Path -Path $RepoLocation -ChildPath "src" - $liveScenarios = Get-ChildItem -Path $srcDir -Recurse -Directory -Filter "LiveTests" | Get-ChildItem -Filter "TestLiveScenarios.ps1" -File | Select-Object -ExpandProperty FullName + $liveScenarios = Get-ChildItem -Path $srcDir -Recurse -Directory -Filter "LiveTests" | Get-ChildItem -Recurse -Filter "TestLiveScenarios.ps1" -File | Select-Object -ExpandProperty FullName $liveScenarios | ForEach-Object { $moduleName = [regex]::match($_, "[\\|\/]src[\\|\/](?[a-zA-Z]+)[\\|\/]").Groups["ModuleName"].Value if (!$PSBoundParameters.ContainsKey("TargetModule") -or $moduleName -in $TargetModule) { diff --git a/tools/VersionController/Program.cs b/tools/VersionController/Program.cs index 5530267b9ad0..c7f6a778fd2b 100644 --- a/tools/VersionController/Program.cs +++ b/tools/VersionController/Program.cs @@ -264,7 +264,7 @@ private static void BumpVersions() } var outputModuleManifestFile = outputModuleManifest.FirstOrDefault(); - if (!string.IsNullOrEmpty(_moduleNameFilter)) { + if (!string.IsNullOrEmpty(_assignedVersion)) { _versionBumper = new VersionBumper(new VersionFileHelper(_rootDirectory, outputModuleManifestFile, projectModuleManifestPath), changedModules,new AzurePSVersion(_assignedVersion), _releaseType); } else { _versionBumper = new VersionBumper(new VersionFileHelper(_rootDirectory, outputModuleManifestFile, projectModuleManifestPath), changedModules, _releaseType);