-
Notifications
You must be signed in to change notification settings - Fork 4k
Add Rollback option to resource group level resources #7134
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
Conversation
...ger/Cmdlets/Implementation/ResourceGroupDeployments/NewAzureResourceGroupDeploymentCmdlet.cs
Outdated
Show resolved
Hide resolved
...ger/Cmdlets/Implementation/ResourceGroupDeployments/NewAzureResourceGroupDeploymentCmdlet.cs
Outdated
Show resolved
Hide resolved
Please either link your review or fill out a new design review from here: https://github.com/Azure/azure-powershell-cmdlet-review-pr |
@maddieclayton filled the following design review https://github.com/Azure/azure-powershell-cmdlet-review-pr/issues/146 |
@chidmdxx Hey Rachid, for some reason, GitHub isn't letting me pull in the latest from the |
@cormacpayne rebased the branch with the latest from upstream |
...ger/Cmdlets/Implementation/ResourceGroupDeployments/NewAzureResourceGroupDeploymentCmdlet.cs
Outdated
Show resolved
Hide resolved
...er/Cmdlets/Implementation/ResourceGroupDeployments/TestAzureResourceGroupDeploymentCmdlet.cs
Outdated
Show resolved
Hide resolved
Accept pipeline input: False | ||
Accept wildcard characters: False | ||
``` | ||
|
||
### -TemplateFile |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove any change to AzureRM.psm1 below
@@ -45,6 +46,12 @@ public class NewAzureResourceGroupDeploymentCmdlet : ResourceWithParameterCmdlet | |||
[ValidateSet("RequestContent", "ResponseContent", "All", "None", IgnoreCase = true)] | |||
public string DeploymentDebugLogLevel { get; set; } | |||
|
|||
[Parameter(Mandatory = false, HelpMessage = "Rollback to the last successful deployment in the resource group, should not be present if -RollBackDeploymentName is used.")] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
these need to be in separate parameter sets - any parameter that is not in any parameter set is in all parameter sets. I can put a PR into your branch to show how this is done.
@@ -66,6 +73,11 @@ public override void ExecuteCmdlet() | |||
ResourceGroupName, | |||
() => | |||
{ | |||
if (RollbackToLastDeployment && !string.IsNullOrEmpty(RollBackDeploymentName)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead, we shoudl do this with parameter sets,
@@ -35,19 +37,37 @@ public class TestAzureResourceGroupDeploymentCmdlet : ResourceWithParameterCmdle | |||
[Parameter(Mandatory = false, ValueFromPipelineByPropertyName = true, HelpMessage = "The deployment mode.")] | |||
public DeploymentMode Mode { get; set; } | |||
|
|||
[Parameter(Mandatory = false, HelpMessage = "Rollback to the last successful deployment in the resource group, should not be present if -RollBackDeploymentName is used.")] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same comment
Description
Checklist
CONTRIBUTING.md
platyPS
module