Update-AzureRmApiManagementDeployment

Updates deployment of an API Management Service.

Syntax

Update-AzureRmApiManagementDeployment
      -ResourceGroupName <String>
      -Name <String>
      -Location <String>
      -Sku <PsApiManagementSku>
      -Capacity <Int32>
      [-VirtualNetwork <PsApiManagementVirtualNetwork>]
      [-VpnType <PsApiManagementVpnType>]
      [-AdditionalRegions <System.Collections.Generic.IList`1[Microsoft.Azure.Commands.ApiManagement.Models.PsApiManagementRegion]>]
      [-PassThru]
      [-DefaultProfile <IAzureContextContainer>]
      [<CommonParameters>]
Update-AzureRmApiManagementDeployment
      -ApiManagement <PsApiManagement>
      [-PassThru]
      [-DefaultProfile <IAzureContextContainer>]
      [<CommonParameters>]

Description

The Update-AzureRmApiManagementDeployment cmdlet updates current deployments of an API Management service.

Examples

Example 1: Update a deployment of an ApiManagement instance

PS C:\>Update-AzureRmApiManagementDeployment -ResourceGroupName "Contoso" -Name "ContosoApi" -Sku "Standard" -Capacity 3

This command updates deployment of an API Management instance to a three unit capacity standard.

Example 2: Get an ApiManagement instance and rescale it

PS C:\>$ApiManagement = Get-AzureRmApiManagement -ResourceGroupName "Contoso" -Name "ContosoApi"
PS C:\> $ApiManagement.Sku = "Premium"
PS C:\> $ApiManagement.Capacity = 5
PS C:\> $ApiManagement.AddRegion("Central US", "Premium", 3)
PS C:\> Update-AzureRmApiManagementDeployment -ApiManagement $ApiManagement

This example gets an Api Management instance, scales it to five premium units and then adds an additional three units to the premium region.

Example 3: Update deployment (external VNET)

PS C:\> $virtualNetwork = New-AzureRmApiManagementVirtualNetwork -Location "East US" -SubnetResourceId "/subscriptions/a8ff56dc-3bc7-4174-a1e8-3726ab15d0e2/resourceGroups/Api-Default-West-US/providers/Microsoft.ClassicNetwork/virtualNetworks/dfVirtualNetwork/subnets/backendSubnet"
PS C:\> Update-AzureRmApiManagementDeployment -ResourceGroupName "ContosoGroup" -Name "ContosoApi" -VirtualNetwork $virtualNetwork -VpnType "External"

This command updates an existing API Management deployment and joins to an external VpnType.

Example 4: Update deployment (internal VNET)

PS C:\> $virtualNetwork = New-AzureRmApiManagementVirtualNetwork -Location "East US" -SubnetResourceId "/subscriptions/a8ff56dc-3bc7-4174-a1e8-3726ab15d0e2/resourceGroups/Api-Default-West-US/providers/Microsoft.ClassicNetwork/virtualNetworks/dfVirtualNetwork/subnets/backendSubnet"
PS C:\> Update-AzureRmApiManagementDeployment -ResourceGroupName "ContosoGroup" -Name "ContosoApi" -VirtualNetwork $virtualNetwork -VpnType "Internal"

This command updates an existing API Management deployment and joins to an internal VpnType.

Required Parameters

-ApiManagement

Specifies the PsApiManagement instance to get deployment configuration from. Use this parameter if the instance already has all the required changes.

Type:Microsoft.Azure.Commands.ApiManagement.Models.PsApiManagement
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
-Capacity

Specifies the SKU capacity of the master Azure API Management deployment region.

Type:Int32
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-Location

Specifies the location of the master API Management deployment region.

To obtain valid locations, use the cmdlet Get-AzureRmResourceProvider -ProviderNamespace "Microsoft.ApiManagement" | where {$_.ResourceTypes[0].ResourceTypeName -eq "service"} | Select-Object Locations

Type:String
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-Name

Specifies the name of API Management that this cmdlet updates.

Type:String
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-ResourceGroupName

Specifies the name of resource group under which API Management exists.

Type:String
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-Sku

Specifies the tier of the master Azure API Management deployment region.

The acceptable values for this parameter are:

  • Developer
  • Standard
  • Premium
Type:Microsoft.Azure.Commands.ApiManagement.Models.PsApiManagementSku
Parameter Sets:Developer, Standard, Premium
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False

Optional Parameters

-AdditionalRegions

Specifies additional deployment regions of Azure API Management.

Type:System.Collections.Generic.IList`1[Microsoft.Azure.Commands.ApiManagement.Models.PsApiManagementRegion]
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-DefaultProfile

The credentials, account, tenant, and subscription used for communication with azure.

Type:Microsoft.Azure.Commands.Common.Authentication.Abstractions.IAzureContextContainer
Aliases:AzureRmContext, AzureCredential
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-PassThru

Returns an object representing the item with which you are working. By default, this cmdlet does not generate any output.

Type:System.Management.Automation.SwitchParameter
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-VirtualNetwork

Specifies the Virtual Network configuration of the master Azure API Management deployment region.

Type:Microsoft.Azure.Commands.ApiManagement.Models.PsApiManagementVirtualNetwork
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False
-VpnType

Specifies the virtual network Type of the API Management deployment. The acceptable values for this parameter are:

  • None. The API Management deployment is not part of any Virtual Network. This is the default value.
  • External. The API Management deployment has an external facing virtual address.
  • Internal. The API Management deployment has an intranet facing virtual address.
Type:Microsoft.Azure.Commands.ApiManagement.Models.PsApiManagementVpnType
Parameter Sets:None, External, Internal
Position:Named
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False

Inputs

PsApiManagement

Parameter 'ApiManagement' accepts value of type 'PsApiManagement' from the pipeline

Outputs

Microsoft.Azure.Commands.ApiManagement.Models.PsApiManagement