File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -180,7 +180,13 @@ while ($runCount -le $NumberOfIterations)
180180 $asToken = NewAzureStackToken - AADTenantId $AADTenantId - EnvironmentDomainFQDN $EnvironmentDomainFQDN - Credentials $ServiceAdminCredentials - ArmEndPoint $AdminArmEndpoint
181181 $defaultSubscription = Get-AzureRmSubscription - SubscriptionName " Default Provider Subscription" - ErrorAction Stop
182182 $asCanaryQuotas = NewAzureStackDefaultQuotas - ResourceLocation $ResourceLocation - SubscriptionId $defaultSubscription.SubscriptionId - AADTenantID $AADTenantID - EnvironmentDomainFQDN $EnvironmentDomainFQDN - Credentials $ServiceAdminCredentials - ArmEndPoint $AdminArmEndPoint
183- New-AzureRMPlan - Name $tenantPlanName - DisplayName $tenantPlanName - ArmLocation $ResourceLocation - ResourceGroup $subscriptionRGName - SubscriptionId $defaultSubscription.SubscriptionId - AdminUri $AdminArmEndPoint - Token $asToken - QuotaIds $asCanaryQuotas - ErrorAction Stop
183+ if ((Get-Module AzureStack).Version -ge [System.Version ] " 1.2.9" )
184+ {
185+ New-AzureRMPlan - Name $tenantPlanName - DisplayName $tenantPlanName - ArmLocation $ResourceLocation - ResourceGroup $subscriptionRGName - QuotaIds $asCanaryQuotas - ErrorAction Stop
186+ }
187+ else {
188+ New-AzureRMPlan - Name $tenantPlanName - DisplayName $tenantPlanName - ArmLocation $ResourceLocation - ResourceGroup $subscriptionRGName - SubscriptionId $defaultSubscription.SubscriptionId - AdminUri $AdminArmEndPoint - Token $asToken - QuotaIds $asCanaryQuotas - ErrorAction Stop
189+ }
184190 }
185191
186192 Invoke-Usecase - Name ' CreateTenantOffer' - Description " Create a tenant offer" - UsecaseBlock `
Original file line number Diff line number Diff line change @@ -44,7 +44,13 @@ function New-AzSTenantOfferAndQuotas
4444 New-AzureRmResourceGroup - Name $Name - Location $Location - ErrorAction Stop
4545
4646 Write-Verbose " Creating plan..." - Verbose
47- $plan = New-AzureRMPlan - Name $Name - DisplayName $Name - ArmLocation $Location - ResourceGroup $Name - SubscriptionId $subscription - QuotaIds $Quotas
47+ if ((Get-Module AzureStack).Version -ge [System.Version ] " 1.2.9" )
48+ {
49+ $plan = New-AzureRMPlan - Name $Name - DisplayName $Name - ArmLocation $Location - ResourceGroup $Name - QuotaIds $Quotas
50+ }
51+ else {
52+ $plan = New-AzureRMPlan - Name $Name - DisplayName $Name - ArmLocation $Location - ResourceGroup $Name - SubscriptionId $subscription - QuotaIds $Quotas
53+ }
4854
4955 Write-Verbose " Creating public offer..." - Verbose
5056 $offer = New-AzureRMOffer - Name $Name - DisplayName $Name - State Public - BasePlanIds @ ($plan.Id ) - ArmLocation $Location - ResourceGroup $Name
You can’t perform that action at this time.
0 commit comments