Skip to content

May breaking change warnings for New-AzVM, New-AzVmss, New-AzGalleryImage #24437

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Mar 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions src/Compute/Compute/ChangeLog.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,10 @@
* Renamed parameter `-AutoOSUpgrade` to `-EnableAutomaticOSUpgrade` in `New-AzVmssConfig` cmdlet for consistency. Using `-AutoOSUpgrade` as parameter name will continue to work as it is added as an alias.
* Upgraded Azure.Core to 1.37.0.
* Az.Compute is updated to use the 2023-07-03 GalleryRP REST API calls.
* Added breaking change warnings for the May 2024 release. The warnings are for:
`New-AzGalleryImageVersion` defaulting to turn on TrustedLaunchSupported and HyperVGeneration to V2.
`New-AzVM` and `New-AzVmss` will default to the image `Windows Server 2022 Azure Edition` instead of `Windows 2016 Datacenter` by default.
`Get-AzVmss` will no longer allow empty values to `ResourceGroupName` and `VMScaleSetName` to avoid a bug where it will just return nothing.

## Version 7.1.2
* Fixed `New-AzVM` when a source image is specified to avoid an error on the `Version` value.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,12 @@
using Microsoft.Azure.Commands.ResourceManager.Common.ArgumentCompleters;
using Microsoft.Azure.Management.Compute;
using Microsoft.Azure.Management.Compute.Models;
using Microsoft.WindowsAzure.Commands.Common.CustomAttributes;
using Microsoft.WindowsAzure.Commands.Utilities.Common;

namespace Microsoft.Azure.Commands.Compute.Automation
{
[GenericBreakingChangeWithVersionAttribute("Starting in May 2024 the \"New-AzGalleryImage\" cmdlet will deploy with the Trusted Launch configuration by default. To know more about Trusted Launch, please visit https://docs.microsoft.com/en-us/azure/virtual-machines/trusted-launch", "12.0.0", "8.0.0")]
[Cmdlet(VerbsCommon.New, ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "GalleryImageDefinition", DefaultParameterSetName = "DefaultParameter", SupportsShouldProcess = true)]
[OutputType(typeof(PSGalleryImage))]
public partial class NewAzureRmGalleryImage : ComputeAutomationBaseCmdlet
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,12 @@
using Microsoft.Azure.Management.Compute;
using Microsoft.Azure.Management.Compute.Models;
using Microsoft.Azure.Management.Internal.Resources.Utilities.Models;
using Microsoft.WindowsAzure.Commands.Common.CustomAttributes;
using Microsoft.WindowsAzure.Commands.Utilities.Common;

namespace Microsoft.Azure.Commands.Compute.Automation
{
[GenericBreakingChangeWithVersionAttribute("Starting in May 2024 the \"Get-AzVmss\" cmdlet will no longer allow an empty value for resource group name and virtual machine scale set name.", "12.0.0", "8.0.0")]
[Cmdlet(VerbsCommon.Get, ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "Vmss", DefaultParameterSetName = "DefaultParameter")]
[OutputType(typeof(PSVirtualMachineScaleSet))]
public partial class GetAzureRmVmss : ComputeAutomationBaseCmdlet
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@

namespace Microsoft.Azure.Commands.Compute.Automation
{
[GenericBreakingChangeWithVersionAttribute("Starting in May 2024 the \"New-AzVmss\" cmdlet will deploy with the image 'Windows Server 2022 Azure Edition' by default. This will make migrating to Trusted Launch easier in the future. To know more about Trusted Launch, please visit https://docs.microsoft.com/en-us/azure/virtual-machines/trusted-launch", "12.0.0", "8.0.0")]
public partial class NewAzureRmVmss : ComputeAutomationBaseCmdlet
{
private const string flexibleOrchestrationMode = "Flexible", uniformOrchestrationMode = "Uniform";
Expand All @@ -51,7 +52,8 @@ public partial class NewAzureRmVmss : ComputeAutomationBaseCmdlet
"Ubuntu2204",
"FlatcarLinuxFreeGen2",
"Win2022Datacenter",
"Win2022AzureEditionCore",
"Win2022AzureEditionCore",
"Win2022AzureEdition",
"Win2019Datacenter",
"Win2016Datacenter",
"Win2012R2Datacenter",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@

namespace Microsoft.Azure.Commands.Compute
{
[GenericBreakingChangeWithVersionAttribute("Starting in May 2024 the \"New-AzVM\" cmdlet will deploy with the image 'Windows Server 2022 Azure Edition' by default. This will make migrating to Trusted Launch easier in the future. To know more about Trusted Launch, please visit https://docs.microsoft.com/en-us/azure/virtual-machines/trusted-launch", "12.0.0", "8.0.0")]
[Cmdlet("New", ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "VM", SupportsShouldProcess = true, DefaultParameterSetName = "SimpleParameterSet")]
[OutputType(typeof(PSAzureOperationResponse), typeof(PSVirtualMachine))]
public class NewAzureVMCommand : VirtualMachineBaseCmdlet
Expand Down Expand Up @@ -221,6 +222,7 @@ public class NewAzureVMCommand : VirtualMachineBaseCmdlet
"FlatcarLinuxFreeGen2",
"Win2022Datacenter",
"Win2022AzureEditionCore",
"Win2022AzureEdition",
"Win2019Datacenter",
"Win2016Datacenter",
"Win2012R2Datacenter",
Expand Down