en-US/about_AzDoEnvironmentApproval.help.txt
|
.NAME
AzDoEnvironmentApproval .SYNOPSIS DSC resource for managing Azure DevOps environment approval checks. .DESCRIPTION This resource configures approval gates on Azure DevOps pipeline environments. When an approval check is configured, deployments to that environment will pause until the required number of approvers have approved the deployment. .PARAMETER ProjectName Key - System.String The name of the Azure DevOps project. This property is mandatory and serves as a key property for the resource. .PARAMETER EnvironmentName Required - System.String The name of the pipeline environment. This is a key property. .PARAMETER Approvers Required - System.String[] .PARAMETER RequiredApproverCount Write - System.UInt32 The minimum number of approvals required. Defaults to 1. .PARAMETER AllowApproverToSelf Write - System.Boolean Whether the user who triggered the pipeline can approve their own deployment. Defaults to $false. .PARAMETER TimeoutInMinutes Write - System.UInt32 How long the approval check waits before timing out. Defaults to 43200 (30 days). .PARAMETER Instructions Write - System.String Instructions shown to approvers. Optional. .EXAMPLE 1 This example shows how to configure approval gates on a pipeline environment in an Azure DevOps project. Configuration Example { Import-DscResource -ModuleName 'AzureDevOpsDscNative' node localhost { AzDoEnvironmentApproval 'AddAzDoEnvironmentApproval' { Ensure = 'Present' ProjectName = 'MyProject' EnvironmentName = 'Production' Approvers = @('approver@example.com') RequiredApproverCount = 1 AllowApproverToSelf = $false TimeoutInMinutes = 1440 Instructions = 'Please review and approve the production deployment.' } } } .EXAMPLE 2 This example shows how to update approval gates on a pipeline environment in an Azure DevOps project. Configuration Example { Import-DscResource -ModuleName 'AzureDevOpsDscNative' node localhost { AzDoEnvironmentApproval 'UpdateAzDoEnvironmentApproval' { Ensure = 'Present' ProjectName = 'MyProject' EnvironmentName = 'Production' Approvers = @('approver1@example.com', 'approver2@example.com') RequiredApproverCount = 2 AllowApproverToSelf = $false TimeoutInMinutes = 2880 Instructions = 'At least 2 approvals required for production deployments.' } } } .EXAMPLE 3 This example shows how to remove approval gates from a pipeline environment in an Azure DevOps project. Configuration Example { Import-DscResource -ModuleName 'AzureDevOpsDscNative' node localhost { AzDoEnvironmentApproval 'RemoveAzDoEnvironmentApproval' { Ensure = 'Absent' ProjectName = 'MyProject' EnvironmentName = 'Production' Approvers = @() } } } |