Skip to content

Commit 1821f8e

Browse files
author
Kimmo Forss
committed
Add playbook options for SAP user credentials
1 parent f288a53 commit 1821f8e

File tree

1 file changed

+59
-0
lines changed

1 file changed

+59
-0
lines changed

articles/sap/automation/tutorial.md

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -908,6 +908,65 @@ For this example configuration, the resource group is `LAB-SECE-DEP05-INFRASTRUC
908908
909909
Select the playbook `1) BoM Downloader` to download the SAP software described in the BOM file into the storage account. Check that the `sapbits` container has all your media for installation.
910910
911+
You can either run the playbook using the configuration menu or directly from the command line.
912+
913+
```bash
914+
915+
cd ${HOME}/Azure_SAP_Automated_Deployment/WORKSPACES/SYSTEM/BOMS/
916+
917+
export ANSIBLE_PRIVATE_KEY_FILE=sshkey
918+
919+
playbook_options=(
920+
--inventory-file="${sap_sid}_hosts.yaml"
921+
--private-key=${ANSIBLE_PRIVATE_KEY_FILE}
922+
--extra-vars="_workspace_directory=`pwd`"
923+
--extra-vars="@sap-parameters.yaml"
924+
--extra-vars="bom_processing=true"
925+
"${@}"
926+
)
927+
928+
# Run the playbook to retrieve the ssh key from the Azure key vault
929+
ansible-playbook "${playbook_options[@]}" ~/Azure_SAP_Automated_Deployment/sap-automation/deploy/ansible/pb_get-sshkey.yaml
930+
931+
# Run the playbook to perform the Operating System configuration
932+
ansible-playbook "${playbook_options[@]}" ~/Azure_SAP_Automated_Deployment/sap-automation/deploy/ansible/playbook_bom_downloader.yaml
933+
934+
935+
```
936+
937+
if you want you can also pass the SAP User credentials as parameters
938+
939+
```bash
940+
941+
cd ${HOME}/Azure_SAP_Automated_Deployment/WORKSPACES/SYSTEM/BOMS/
942+
943+
sap_username=<sap-username>
944+
sap_user_password='<sap-password>'
945+
946+
export ANSIBLE_PRIVATE_KEY_FILE=sshkey
947+
948+
playbook_options=(
949+
--inventory-file="${sap_sid}_hosts.yaml"
950+
--private-key=${ANSIBLE_PRIVATE_KEY_FILE}
951+
--extra-vars="_workspace_directory=`pwd`"
952+
--extra-vars="@sap-parameters.yaml"
953+
--extra-vars="s_user=${sap_username}"
954+
--extra-vars="s_password=${sap_user_password}"
955+
--extra-vars="bom_processing=true"
956+
"${@}"
957+
)
958+
959+
# Run the playbook to retrieve the ssh key from the Azure key vault
960+
ansible-playbook "${playbook_options[@]}" ~/Azure_SAP_Automated_Deployment/sap-automation/deploy/ansible/pb_get-sshkey.yaml
961+
962+
# Run the playbook to perform the Operating System configuration
963+
ansible-playbook "${playbook_options[@]}" ~/Azure_SAP_Automated_Deployment/sap-automation/deploy/ansible/playbook_bom_downloader.yaml
964+
965+
966+
```
967+
968+
969+
911970
912971
## SAP application installation
913972

0 commit comments

Comments
 (0)