Skip to content

Commit 27525ba

Browse files
authored
Merge pull request #180351 from KimForss/master
Update automation-tutorial.md
2 parents d7ba954 + ea4a205 commit 27525ba

File tree

1 file changed

+27
-24
lines changed

1 file changed

+27
-24
lines changed

articles/virtual-machines/workloads/sap/automation-tutorial.md

Lines changed: 27 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ cd ~/Azure_SAP_Automated_Deployment/sap-automation
137137
Optionally, validate the version of Terraform, and the Azure Command-Line Interface (Azure CLI) available on your instance of the Cloud Shell.
138138

139139
```bash
140-
deploy/scripts/check_workstation.sh
140+
deploy/scripts/helpers/check_workstation.sh
141141
```
142142

143143
To run the automation framework, update to the following versions.
@@ -201,7 +201,7 @@ Copy the sample configurations to a local workspace directory:
201201
```bash
202202
cd ~/Azure_SAP_Automated_Deployment
203203

204-
cp -Rp ./sap-automation/training_materials/WORKSPACES ./
204+
cp -Rp ./sap-automation/training-materials/WORKSPACES ./
205205
```
206206

207207
Open VS Code from Cloud Shell
@@ -228,7 +228,7 @@ Find the appropriate four-character code that corresponds to the Azure region yo
228228

229229
Find the Terraform variable files in the appropriate subfolder. For example, the **DEPLOYER** terraform variable file might look like:
230230

231-
```bash
231+
```terraform
232232
# The environment value is a mandatory field, it is used for partitioning the environments, for example, PROD and NP.
233233
environment="MGMT"
234234
# The location/region value is a mandatory field, it is used to control where the resources are deployed
@@ -267,17 +267,18 @@ export subscriptionID=<subscriptionID>
267267
export appId=<appID>
268268
export spn_secret="<password>"
269269
export tenant_id=<tenant>
270+
export region_code=NOEU
270271

271272
export DEPLOYMENT_REPO_PATH="${HOME}/Azure_SAP_Automated_Deployment/sap-automation"
272273
export ARM_SUBSCRIPTION_ID="${subscriptionID}"
273274

274-
${DEPLOYMENT_REPO_PATH}/deploy/scripts/prepare_region.sh \
275-
--deployer_parameter_file DEPLOYER/MGMT-NOEU-DEP00-INFRASTRUCTURE/MGMT-NOEU-DEP00-INFRASTRUCTURE.tfvars \
276-
--library_parameter_file LIBRARY/MGMT-NOEU-SAP_LIBRARY/MGMT-NOEU-SAP_LIBRARY.tfvars \
277-
--subscription $subscriptionID \
278-
--spn_id $appID \
279-
--spn_secret $spn_secret \
280-
--tenant_id $tenant_id
275+
${DEPLOYMENT_REPO_PATH}/deploy/scripts/prepare_region.sh \
276+
--deployer_parameter_file DEPLOYER/MGMT-${region_code}-DEP00-INFRASTRUCTURE/MGMT-${region_code}-DEP00-INFRASTRUCTURE.tfvars \
277+
--library_parameter_file LIBRARY/MGMT-${region_code}-SAP_LIBRARY/MGMT-${region_code}-SAP_LIBRARY.tfvars \
278+
--subscription $subscriptionID \
279+
--spn_id $appID \
280+
--spn_secret $spn_secret \
281+
--tenant_id $tenant_id --force
281282
```
282283

283284
If you run into authentication issues, run `az logout` to log out. Clear `token-cache`, then run `az login` to reauthenticate.
@@ -532,18 +533,19 @@ export spn_secret="<password>"
532533
export tenant_id=<tenant>
533534
export storage_account=<storageaccountName>
534535
export statefile_subscription=<subscriptionID>
536+
export region_code=NOEU
535537
key_vault=<vaultID>
536538
537-
${DEPLOYMENT_REPO_PATH}/deploy/scripts/install_workloadzone.sh \
538-
--parameterfile ./DEV-NOEU-SAP01-INFRASTRUCTURE.tfvars \
539-
--deployer_environment MGMT \
540-
--deployer_tfstate_key MGMT-NOEU-DEP00-INFRASTRUCTURE.terraform.tfstate \
541-
--keyvault $key_vault \
542-
--storageaccountname $storage_account \
543-
--state_subscription $statefile_subscription \
544-
--subscription $subscriptionID \
545-
--spn_id $appID \
546-
--spn_secret $spn_secret \
539+
${DEPLOYMENT_REPO_PATH}/deploy/scripts/install_workloadzone.sh \
540+
--parameterfile ./DEV-${region_code}-SAP01-INFRASTRUCTURE.tfvars \
541+
--deployer_environment MGMT \
542+
--deployer_tfstate_key MGMT-${region_code}-DEP00-INFRASTRUCTURE.terraform.tfstate \
543+
--keyvault $key_vault \
544+
--storageaccountname $storage_account \
545+
--state_subscription $statefile_subscription \
546+
--subscription $subscriptionID \
547+
--spn_id $appID \
548+
--spn_secret $spn_secret \
547549
--tenant_id $tenant_id
548550
```
549551

@@ -567,10 +569,11 @@ Deploy the SAP system.
567569

568570
```bash
569571
cd ~/Azure_SAP_Automated_Deployment/WORKSPACES/SYSTEM/DEV-XXXX-SAP01-X00
572+
export region_code=NOEU
570573
571-
${DEPLOYMENT_REPO_PATH}/deploy/scripts/installer.sh \
572-
--parameterfile DEV-XXXX-SAP01-X00.tfvars \
573-
--type sap_system \
574+
${DEPLOYMENT_REPO_PATH}/deploy/scripts/installer.sh \
575+
--parameterfile DEV-${region_code}-SAP01-X00.tfvars \
576+
--type sap_system \
574577
--auto-approve
575578
```
576579

@@ -580,7 +583,7 @@ The deployment command for the `northeurope` example will look like:
580583
cd ~/Azure_SAP_Automated_Deployment/WORKSPACES/SYSTEM/DEV-NOEU-SAP01-X00
581584
582585
${DEPLOYMENT_REPO_PATH}/deploy/scripts/installer.sh \
583-
--parameterfile DEV-NOEU-SAP01-X00.tfvars \
586+
--parameterfile DEV-NOEU-SAP01-X00.tfvars \
584587
--type sap_system \
585588
--auto-approve
586589
```

0 commit comments

Comments
 (0)