Library with common functions for Microsoft SDAF deployment automation that help with preparation of 'SAP-SYSTEMS' tfvars file. File is generated according to example template: https://github.com/Azure/SAP-automation-samples/blob/main/Terraform/WORKSPACES/SYSTEM/LAB-SECE-SAP04-L00/LAB-SECE-SAP04-L00.tfvars
create_sap_systems_tfvars(workload_vnet_code=>'SAP04' [, av_zones=>'true']);
Creates data structure with content of sap systems tfvars file according to provided arguments and required OpenQA settings. Data structure converted into tfvars format is written into target file.
av_zones: Define if availability zones should be used. Default: true
workload_vnet_code: Workload zone VNET code.
define_workload_environment(environment=>'LAB', location=>'swedencentral');
Returns tfvars environment definitions section in HASHREF format. Example: {environment : '"LAB"', location : '"swedencentral"'} Pay attention to double quoting strings. They are very important in resulting file.
environment: SDAF environment
location: Public cloud location
define_networking(workload_vnet_code=>'SAP04');
Returns tfvars networking definitions section in HASHREF format. Example: {network_logical_name : '"VNET01"', use_private_endpoint : 'true' ... } Pay attention to double quoting strings. They are very important in resulting file.
workload_vnet_code: Workload zone VNET code.
define_cluster_settings();
Returns tfvars cluster definitions section in HASHREF format. Example: {scs_cluster_type : '"AFA"', use_msi_for_clusters : 'true' ... } Pay attention to double quoting strings. They are very important in resulting file.
define_database_tier(high_availability=>'true', av_zones=>'false');
Returns tfvars database tier definitions section in HASHREF format. Example: {database_high_availability : 'true', database_use_avset : 'true' ... } Pay attention to double quoting strings. They are very important in resulting file.
high_availability: Enable database high availability deployment.
av_zones: Define if availability zones should be used.
define_application_tier(enable_app_tier_deployment=>'true', sap_sid=>'ABC');
Returns tfvars database tier definitions section in HASHREF format. Example: {enable_app_tier_deployment : 'true', sid : '"P00"' ... } Pay attention to double quoting strings. They are very important in resulting file.
enable_app_tier_deployment: Enable deployment of Netweaver stack.
sap_sid: Define Netweaver SAP system id.
define_sap_central_services(scs_server_count=>'1', sap_sid=>'ABC', high_availability=>'true');
Returns tfvars sap central services definitions section in HASHREF format. Example: {scs_server_count : '1', scs_server_use_ppg : 'true' ... } Pay attention to double quoting strings. They are very important in resulting file.
scs_server_count: Number of ASCS servers.
sap_sid: Define Netweaver SAP system id.
high_availability: Enable database high availability deployment.
define_application_servers(app_server_count=>'3');
Returns tfvars sap application server definitions section in HASHREF format. Example: {scs_server_count : '1', scs_server_use_ppg : 'true' ... } Pay attention to double quoting strings. They are very important in resulting file.
app_server_count: Number of application servers. Value '1' will deploy only PAS, anything above will deploy additional app servers.
define_miscellaneous_settings();
Returns tfvars miscellaneous settings section in HASHREF format. Example: {resource_offset : '1', deploy_application_security_groups : 'true' ... } Pay attention to double quoting strings. They are very important in resulting file.
define_nfs_settings();
Returns tfvars NFS related setting section in HASHREF format. NFS storage is used to distribute installation media across all nodes. NFS storage is served by Hana DB node in case only database is installed, otherwise it is ASCS node that serves media. Example: {NFS_provider : '"AFS"', ANF_HANA_use_AVG : 'false' ... } Pay attention to double quoting strings. They are very important in resulting file.
define_vm_images(os_image=>'suse:sles-sap-15-sp5:gen2:latest');
VM OS image tfvars setting definition. Currently all VMs use the same OS image. Both BYOS and PAYG images can be used. Example: {source_image_id : '"suse:sles-sap-15-sp5:gen2:latest"', publisher : '"SUSE"' ... } Pay attention to double quoting strings. They are very important in resulting file.
os_image: BYOS or PAYG image ID.