Skip to content
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

Update tier3.bicep Creation in correct Subscription #726

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion src/bicep/add-ons/tier3/tier3.bicep
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@ var calculatedTags = union(tags, defaultTags)

module resourceGroup '../../modules/resource-group.bicep' = {
name: workloadResourceGroupName
scope: subscription(workloadSubscriptionId)
params: {
name: workloadResourceGroupName
location: location
Expand All @@ -128,7 +129,7 @@ module resourceGroup '../../modules/resource-group.bicep' = {

module spokeNetwork '../../core/spoke-network.bicep' = {
name: 'spokeNetwork'
scope: az.resourceGroup(resourceGroup.name)
scope: az.resourceGroup(workloadSubscriptionId, resourceGroup.name)
params: {
tags: calculatedTags
location:location
Expand Down Expand Up @@ -157,6 +158,7 @@ module spokeNetwork '../../core/spoke-network.bicep' = {

module workloadVirtualNetworkPeerings '../../core/spoke-network-peering.bicep' = {
name: take('${workloadName}-to-hub-vnet-peering', 64)
scope: subscription(workloadSubscriptionId)
params: {
spokeName: workloadName
spokeResourceGroupName: resourceGroup.name
Expand Down