Freigeben über


Get-AzureResourceGroupDeployment

Get-AzureResourceGroupDeployment

Gets the deployments in a resource group.

Syntax

Parameter Set: Default
Get-AzureResourceGroupDeployment [-ResourceGroupName] <String> [[-Name] <String> ] [[-ProvisioningState] <String> ] [-Profile <AzureProfile> ] [ <CommonParameters>]

Detailed Description

The Get-AzureResourceGroupDeployment cmdlet gets the deployments in an Azure resource group. Specify the name and provisioning state to return only certain deployments.

A deployment is the operation that makes the resources in the resource group available for use. For more information about Azure resources and Azure resource groups, see the New-AzureResourceGroup cmdlet.

You can use this cmdlet for tracking. For debugging, use it with the Get-AzureResourceGroupLog cmdlet.

Parameters

-Name<String>

Specifies the name of the deployment group that this cmdlet retrieves.

Aliases

DeploymentName

Required?

false

Position?

2

Default Value

none

Accept Pipeline Input?

true(ByPropertyName)

Accept Wildcard Characters?

false

-Profile<AzureProfile>

Specifies the Azure profile from which this cmdlet reads. If you do not specify a profile, this cmdlet reads from the local default profile.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ProvisioningState<String>

Specifies a provisioning state. This cmdlet retrieves deployments in the provisioning state that this parameter specifies.

Aliases

none

Required?

false

Position?

3

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ResourceGroupName<String>

Specifies the name of the resource group for which this cmdlet gets deployments.

Aliases

none

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

true(ByPropertyName)

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 (https://go.microsoft.com/fwlink/p/?LinkID=113216).

Inputs

The input type is the type of the objects that you can pipe to the cmdlet.

  • String

    This cmdlet accepts deployment name or resource group name.

Outputs

The output type is the type of the objects that the cmdlet emits.

  • Microsoft.Azure.Commands.ResourceManagement.Models. PSResourceGroupDeployment

    This cmdlet returns resource group deployments.

Examples

Example 1: Get all deployments for a resource group

This command gets all deployments for the resource group named ContosoLabsRG. The output shows a deployment for a WordPress blog that used a gallery template.

Get-AzureResourceGroupDeployment -ResourceGroupName "ContosoLabsRG"

Example 2: Get a deployment by name

This command gets the DeployWebsite17 deployment of the resource group named ContosoLabsRG. You can assign a name to a deployment when you create it by using the New-AzureResourceGroup or New-AzureResourceGroupDeployment cmdlets. If you do not assign a name, the cmdlets provide a default name based on the template that is used to create the deployment.

Get-AzureResourceGroupDeployment -ResourceGroupName "ContosoLabsRG" -Name "DeployWebsite17"

Example 3: Get a deployment by provisioning state

This command gets the deployments of the resource group named ContosoLabsRG that are not yet provisioned.

Get-AzureResourceGroupDeployment -ResourceGroupName "ContosoLabsRG" -ProvisioningState "NotProvisioned"

Example 4: Get the deployments of all resource groups

This command gets all resource groups in your subscription by using the Get-AzureResourceGroup cmdlet. The command passes the resource groups to the current cmdlet by using the pipeline operator. The current cmdlet gets all deployments of each resource group, and passes the results to the Format-Table cmdlet. That cmdlet formats the results.

Get-AzureResourceGroup | Get-AzureResourceGroupDeployment | Format-Table ResourceGroupName, DeploymentName, ProvisioningState

New-AzureResourceGroupDeployment

Stop-AzureResourceGroupDeployment

Get-AzureResourceGroupLog

Get-AzureResourceGroup

New-AzureResourceGroup

Format-Table