Skip to content

Commit

Permalink
adding variables the possibility to be saved by saveenv.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
Federico Arambarri committed Aug 30, 2023
1 parent a33bb0f commit 01e39fb
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions 04-networking.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,11 +75,11 @@ The following two resource groups will be created and populated with networking
> :book: The networking team receives a request from an app team in business unit (BU) 0001 for a network spoke to house their new AKS-based application (Internally know as Application ID: A0008). The network team talks with the app team to understand their requirements and aligns those needs with Microsoft's best practices for a general-purpose AKS cluster deployment. They capture those specific requirements and deploy the spoke, aligning to those specs, and connecting it to the matching regional hub.

```bash
RESOURCEID_VNET_HUB=$(az deployment group show -g rg-enterprise-networking-hubs -n hub-default --query properties.outputs.hubVnetId.value -o tsv)
echo RESOURCEID_VNET_HUB: $RESOURCEID_VNET_HUB
export RESOURCEID_VNET_HUB_AKS_BASELINE=$(az deployment group show -g rg-enterprise-networking-hubs -n hub-default --query properties.outputs.hubVnetId.value -o tsv)
echo RESOURCEID_VNET_HUB_AKS_BASELINE: $RESOURCEID_VNET_HUB_AKS_BASELINE
# [This takes about four minutes to run.]
az deployment group create -g rg-enterprise-networking-spokes -f networking/spoke-BU0001A0008.bicep -p location=eastus2 hubVnetResourceId="${RESOURCEID_VNET_HUB}"
az deployment group create -g rg-enterprise-networking-spokes -f networking/spoke-BU0001A0008.bicep -p location=eastus2 hubVnetResourceId="${RESOURCEID_VNET_HUB_AKS_BASELINE}"
```

The spoke creation will emit the following:
Expand All @@ -93,11 +93,11 @@ The following two resource groups will be created and populated with networking
> :book: Now that their regional hub has its first spoke, the hub can no longer run off of the generic hub template. The networking team creates a named hub template (e.g. `hub-eastus2.bicep`) to forever represent this specific hub and the features this specific hub needs in order to support its spokes' requirements. As new spokes are attached and new requirements arise for the regional hub, they will be added to this template file.
```bash
RESOURCEID_SUBNET_NODEPOOLS=$(az deployment group show -g rg-enterprise-networking-spokes -n spoke-BU0001A0008 --query properties.outputs.nodepoolSubnetResourceIds.value -o json)
echo RESOURCEID_SUBNET_NODEPOOLS: $RESOURCEID_SUBNET_NODEPOOLS
export RESOURCEID_SUBNET_NODEPOOLS_AKS_BASELINE=$(az deployment group show -g rg-enterprise-networking-spokes -n spoke-BU0001A0008 --query properties.outputs.nodepoolSubnetResourceIds.value -o json)
echo RESOURCEID_SUBNET_NODEPOOLS_AKS_BASELINE: $RESOURCEID_SUBNET_NODEPOOLS_AKS_BASELINE
# [This takes about ten minutes to run.]
az deployment group create -g rg-enterprise-networking-hubs -f networking/hub-regionA.bicep -p location=eastus2 nodepoolSubnetResourceIds="${RESOURCEID_SUBNET_NODEPOOLS}"
az deployment group create -g rg-enterprise-networking-hubs -f networking/hub-regionA.bicep -p location=eastus2 nodepoolSubnetResourceIds="${RESOURCEID_SUBNET_NODEPOOLS_AKS_BASELINE}"
```
> :book: At this point the networking team has delivered a spoke in which BU 0001's app team can lay down their AKS cluster (ID: A0008). The networking team provides the necessary information to the app team for them to reference in their infrastructure-as-code artifacts.
Expand Down

0 comments on commit 01e39fb

Please sign in to comment.