From 07183f9b9189f5e4f0280e0ac7e7c7220582ad6f Mon Sep 17 00:00:00 2001 From: surajsbharadwaj Date: Sat, 11 Oct 2025 17:25:34 +0200 Subject: [PATCH 1/7] chore: new solutions --- solutions/single-hana-instance/README.md | 73 +++++++ solutions/single-hana-instance/main.tf | 66 ++++++ solutions/single-hana-instance/outputs.tf | 16 ++ solutions/single-hana-instance/provider.tf | 33 +++ solutions/single-hana-instance/variables.tf | 204 ++++++++++++++++++ solutions/single-hana-instance/version.tf | 13 ++ solutions/single-netweaver-instance/README.md | 67 ++++++ solutions/single-netweaver-instance/main.tf | 63 ++++++ .../single-netweaver-instance/outputs.tf | 16 ++ .../single-netweaver-instance/provider.tf | 33 +++ .../single-netweaver-instance/variables.tf | 195 +++++++++++++++++ .../single-netweaver-instance/version.tf | 13 ++ 12 files changed, 792 insertions(+) create mode 100644 solutions/single-hana-instance/README.md create mode 100644 solutions/single-hana-instance/main.tf create mode 100644 solutions/single-hana-instance/outputs.tf create mode 100644 solutions/single-hana-instance/provider.tf create mode 100644 solutions/single-hana-instance/variables.tf create mode 100644 solutions/single-hana-instance/version.tf create mode 100644 solutions/single-netweaver-instance/README.md create mode 100644 solutions/single-netweaver-instance/main.tf create mode 100644 solutions/single-netweaver-instance/outputs.tf create mode 100644 solutions/single-netweaver-instance/provider.tf create mode 100644 solutions/single-netweaver-instance/variables.tf create mode 100644 solutions/single-netweaver-instance/version.tf diff --git a/solutions/single-hana-instance/README.md b/solutions/single-hana-instance/README.md new file mode 100644 index 00000000..25a21861 --- /dev/null +++ b/solutions/single-hana-instance/README.md @@ -0,0 +1,73 @@ +# Provisioning a single tuned Power Virtual Server for SAP HANA + +This example deploys a single Power Virtual Server instance that is tuned and ready to host an SAP HANA database. + +It provisions the following components in IBM Cloud: + +* Creates an IBM® Power Virtual Server instance in an existing PowerVS workspace (which contains a public SSH key, a pre-existing subnet, and a pre-imported OS image). +* Creates and attaches volumes to the instance. +* Automatically creates the required file systems for SAP HANA. +* Provides an option for users to define a custom storage configuration if needed. +* (Optional) Initializes the instance by configuring proxy settings and network services (NTP, DNS, NFS). +* (Optional) Tunes the OS for SAP HANA. +* Supports bring-your-own-license (BYOL) for RHEL/SLES images. +* Does **not** install SAP HANA. + +--- + +Would you like me to **combine both SAP Application Server and HANA** into a single doc (with separate sections), or keep them as two standalone docs? + + + +### Requirements + +| Name | Version | +|------|---------| +| [terraform](#requirement\_terraform) | >= 1.9.0 | +| [ibm](#requirement\_ibm) | =1.83.3 | + +### Modules + +| Name | Source | Version | +|------|--------|---------| +| [configure\_os\_for\_sap](#module\_configure\_os\_for\_sap) | ../../modules/ansible | n/a | +| [hana\_storage\_calculation](#module\_hana\_storage\_calculation) | ../../modules/pi-hana-storage-config | n/a | +| [sap\_hana\_instance](#module\_sap\_hana\_instance) | terraform-ibm-modules/powervs-instance/ibm | 2.8.2 | + +### Resources + +No resources. + +### Inputs + +| Name | Description | Type | Default | Required | +|------|-------------|------|---------|:--------:| +| [ansible\_vault\_password](#input\_ansible\_vault\_password) | Vault password to encrypt ansible playbooks that contain sensitive information. Required with customer provided linux subscription (powervs\_os\_registration). Password requirements: 15-100 characters and at least one uppercase letter, one lowercase letter, one number, and one special character. Allowed characters: A-Z, a-z, 0-9, !#$%&()*+-.:;<=>?@[]\_{\|}~. | `string` | `null` | no | +| [ibmcloud\_api\_key](#input\_ibmcloud\_api\_key) | The IBM Cloud platform API key needed to deploy IAM enabled resources. | `string` | n/a | yes | +| [powervs\_boot\_image\_storage\_tier](#input\_powervs\_boot\_image\_storage\_tier) | Storage type for server deployment. If storage type is not provided the storage type will default to tier3. Possible values tier0, tier1 and tier3 | `string` | `null` | no | +| [powervs\_deployment\_target](#input\_powervs\_deployment\_target) | The deployment of a dedicated host. Max items: 1, id is the uuid of the host group or host. type is the deployment target type, supported values are host and hostGroup |
list(object(
{
type = string
id = string
}
))
| `null` | no | +| [powervs\_hana\_instance\_additional\_storage\_config](#input\_powervs\_hana\_instance\_additional\_storage\_config) | Additional File systems to be created and attached to PowerVS SAP HANA instance. 'size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the target mount point on OS. |
list(object({
name = string
size = string
count = string
tier = string
mount = string
}))
|
[
{
"count": "1",
"mount": "/usr/sap",
"name": "usrsap",
"size": "50",
"tier": "tier3"
}
]
| no | +| [powervs\_hana\_instance\_custom\_storage\_config](#input\_powervs\_hana\_instance\_custom\_storage\_config) | Custom file systems to be created and attached to PowerVS SAP HANA instance. 'size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the target mount point on OS. |
list(object({
name = string
size = string
count = string
tier = string
mount = string
pool = optional(string)
}))
|
[
{
"count": "",
"mount": "",
"name": "",
"size": "",
"tier": ""
}
]
| no | +| [powervs\_hana\_instance\_sap\_profile\_id](#input\_powervs\_hana\_instance\_sap\_profile\_id) | PowerVS SAP HANA instance profile to use. Must be one of the supported profiles. See [here](https://cloud.ibm.com/docs/sap?topic=sap-hana-iaas-offerings-profiles-power-vs). File system sizes are automatically calculated. Override automatic calculation by setting values in optional parameter 'powervs\_hana\_instance\_custom\_storage\_config'. | `string` | `"sh2-4x256"` | no | +| [powervs\_image\_name](#input\_powervs\_image\_name) | Image name used for PowerVS instance. Run 'ibmcloud pi images' to list available images. | `string` | n/a | yes | +| [powervs\_instance\_init\_linux](#input\_powervs\_instance\_init\_linux) | Configures a PowerVS linux instance to have internet access by setting proxy on it, updates os and create filesystems using ansible collection [ibm.power\_linux\_sap collection](https://galaxy.ansible.com/ui/repo/published/ibm/power_linux_sap/). where 'proxy\_host\_or\_ip\_port' E.g., 10.10.10.4:3128 , 'bastion\_host\_ip' is public IP of bastion/jump host to access the private IP of created linux PowerVS instance. |
object(
{
enable = bool
bastion_host_ip = string
ansible_host_or_ip = string
}
)
|
{
"ansible_host_or_ip": "",
"bastion_host_ip": "",
"enable": false
}
| no | +| [powervs\_instance\_name](#input\_powervs\_instance\_name) | Name of instance which will be created. Must be less than 13 characters. | `string` | n/a | yes | +| [powervs\_network\_services\_config](#input\_powervs\_network\_services\_config) | Configures network services NTP, NFS and DNS on PowerVS instance. Requires 'powervs\_instance\_init\_linux' to be specified as internet access is required to download ansible collection [ibm.power\_linux\_sap collection](https://galaxy.ansible.com/ui/repo/published/ibm/power_linux_sap/) to configure these services. The 'opts' attribute can take in comma separated values. |
object(
{
squid = object({ enable = bool, squid_server_ip_port = string, no_proxy_hosts = string })
nfs = object({ enable = bool, nfs_server_path = string, nfs_client_path = string, opts = string, fstype = string })
dns = object({ enable = bool, dns_server_ip = string })
ntp = object({ enable = bool, ntp_server_ip = string })
}
)
|
{
"dns": {
"dns_server_ip": "",
"enable": false
},
"nfs": {
"enable": false,
"fstype": "",
"nfs_client_path": "",
"nfs_server_path": "",
"opts": ""
},
"ntp": {
"enable": false,
"ntp_server_ip": ""
},
"squid": {
"enable": false,
"no_proxy_hosts": "",
"squid_server_ip_port": ""
}
}
| no | +| [powervs\_networks](#input\_powervs\_networks) | Existing list of private subnet ids to be attached to an instance. The first element will become the primary interface. Run 'ibmcloud pi subnets' to list available subnets. |
list(
object({
name = string
id = string
cidr = optional(string)
})
)
| n/a | yes | +| [powervs\_os\_registration\_password](#input\_powervs\_os\_registration\_password) | If you're using a byol or a custom RHEL/SLES image for SAP HANA and Netweaver you need to provide your OS registration credentials here. Leave empty if you're using an IBM provided subscription (FLS). | `string` | `null` | no | +| [powervs\_os\_registration\_username](#input\_powervs\_os\_registration\_username) | If you're using a byol or a custom RHEL/SLES image for SAP HANA and Netweaver you need to provide your OS registration credentials here. Leave empty if you're using an IBM provided subscription (FLS). | `string` | `null` | no | +| [powervs\_server\_type](#input\_powervs\_server\_type) | By default SAP profile will be deployed on default system type. Override this to specify the type of system on which to create the VM. Supported values are s922/e980/s1022/e1050/e1080/s1122/e1150/e1180. Mandatory when using dedicated hosts. | `string` | `null` | no | +| [powervs\_ssh\_public\_key\_name](#input\_powervs\_ssh\_public\_key\_name) | Name of the existing PowerVS SSH public key. | `string` | n/a | yes | +| [powervs\_workspace\_guid](#input\_powervs\_workspace\_guid) | Existing GUID of the PowerVS workspace. The GUID of the service instance associated with an account. | `string` | n/a | yes | +| [powervs\_zone](#input\_powervs\_zone) | IBM Cloud PowerVS zone. | `string` | n/a | yes | +| [sap\_domain](#input\_sap\_domain) | SAP network domain name. | `string` | `"sap.com"` | no | +| [ssh\_private\_key](#input\_ssh\_private\_key) | SSH private key to access the PowerVS instance via bastion host. | `string` | `""` | no | + +### Outputs + +| Name | Description | +|------|-------------| +| [pi\_instance\_primary\_ip](#output\_pi\_instance\_primary\_ip) | IP address of the primary network interface of IBM PowerVS instance. | +| [pi\_instance\_private\_ips](#output\_pi\_instance\_private\_ips) | All private IP addresses (as a list) of IBM PowerVS instance. | +| [pi\_storage\_configuration](#output\_pi\_storage\_configuration) | Storage configuration of PowerVS instance. | + diff --git a/solutions/single-hana-instance/main.tf b/solutions/single-hana-instance/main.tf new file mode 100644 index 00000000..fbecd9bb --- /dev/null +++ b/solutions/single-hana-instance/main.tf @@ -0,0 +1,66 @@ +##################################################### +# Deploy PowerVS Instance +##################################################### + +module "hana_storage_calculation" { + source = "../../modules/pi-hana-storage-config" + pi_hana_instance_sap_profile_id = var.powervs_hana_instance_sap_profile_id + pi_hana_instance_additional_storage_config = var.powervs_hana_instance_additional_storage_config + pi_hana_instance_custom_storage_config = var.powervs_hana_instance_custom_storage_config +} + +module "sap_hana_instance" { + source = "terraform-ibm-modules/powervs-instance/ibm" + version = "2.8.2" + + pi_workspace_guid = var.powervs_workspace_guid + pi_ssh_public_key_name = var.powervs_ssh_public_key_name + pi_image_id = var.powervs_image_name + pi_instance_name = var.powervs_instance_name + pi_boot_image_storage_tier = var.powervs_boot_image_storage_tier + pi_sap_profile_id = var.powervs_hana_instance_sap_profile_id + pi_server_type = var.powervs_server_type + pi_deployment_target = var.powervs_deployment_target + pi_networks = var.powervs_networks + pi_storage_config = module.hana_storage_calculation.pi_hana_storage_config + ansible_vault_password = var.ansible_vault_password + pi_instance_init_linux = merge(var.powervs_instance_init_linux, + { + ssh_private_key = var.ssh_private_key, + custom_os_registration = ( + try(trim(var.powervs_os_registration_username), "") != "" && + try(trim(var.powervs_os_registration_password), "") != "" + ) ? { + username = var.powervs_os_registration_username + password = var.powervs_os_registration_password + } : null + + }) + pi_network_services_config = var.powervs_network_services_config +} + +module "configure_os_for_sap" { + + source = "../../modules/ansible" + depends_on = [module.sap_hana_instance] + count = var.powervs_instance_init_linux.enable ? 1 : 0 + + bastion_host_ip = var.powervs_instance_init_linux.bastion_host_ip + ansible_host_or_ip = var.powervs_instance_init_linux.ansible_host_or_ip + ssh_private_key = var.ssh_private_key + configure_ansible_host = true + + src_script_template_name = "configure-os-for-sap/ansible_exec.sh.tftpl" + dst_script_file_name = "${var.powervs_instance_name}_configure_os_for_sap.sh" + + src_playbook_template_name = "configure-os-for-sap/playbook-configure-os-for-sap.yml.tftpl" + dst_playbook_file_name = "${var.powervs_instance_name}-playbook-configure-os-for-sap.yml" + playbook_template_vars = { + "sap_solution" : "HANA", + "sap_domain" : var.sap_domain + } + + src_inventory_template_name = "pi-instance-inventory.tftpl" + dst_inventory_file_name = "${var.powervs_instance_name}-instance-inventory" + inventory_template_vars = { "pi_instance_management_ip" : module.sap_hana_instance.pi_instance_primary_ip } +} diff --git a/solutions/single-hana-instance/outputs.tf b/solutions/single-hana-instance/outputs.tf new file mode 100644 index 00000000..1936e013 --- /dev/null +++ b/solutions/single-hana-instance/outputs.tf @@ -0,0 +1,16 @@ +############################################################################## +# Outputs +output "pi_instance_primary_ip" { + description = "IP address of the primary network interface of IBM PowerVS instance." + value = module.sap_hana_instance.pi_instance_primary_ip +} + +output "pi_instance_private_ips" { + description = "All private IP addresses (as a list) of IBM PowerVS instance." + value = module.sap_hana_instance.pi_instance_private_ips +} + +output "pi_storage_configuration" { + description = "Storage configuration of PowerVS instance." + value = module.sap_hana_instance.pi_storage_configuration +} diff --git a/solutions/single-hana-instance/provider.tf b/solutions/single-hana-instance/provider.tf new file mode 100644 index 00000000..bf95131c --- /dev/null +++ b/solutions/single-hana-instance/provider.tf @@ -0,0 +1,33 @@ +locals { + ibm_powervs_zone_region_map = { + "syd04" = "syd" + "syd05" = "syd" + "sao01" = "sao" + "sao04" = "sao" + "tor01" = "tor" + "mon01" = "mon" + "eu-de-1" = "eu-de" + "eu-de-2" = "eu-de" + "mad02" = "mad" + "mad04" = "mad" + "lon04" = "lon" + "lon06" = "lon" + "osa21" = "osa" + "tok04" = "tok" + "us-south" = "us-south" + "dal10" = "us-south" + "dal12" = "us-south" + "dal14" = "us-south" + "us-east" = "us-east" + "wdc06" = "us-east" + "wdc07" = "us-east" + "wdc06-pvs-01" = "us-east" + } + +} + +provider "ibm" { + region = lookup(local.ibm_powervs_zone_region_map, var.powervs_zone, null) + zone = var.powervs_zone + ibmcloud_api_key = var.ibmcloud_api_key != null ? var.ibmcloud_api_key : null +} diff --git a/solutions/single-hana-instance/variables.tf b/solutions/single-hana-instance/variables.tf new file mode 100644 index 00000000..9bb78977 --- /dev/null +++ b/solutions/single-hana-instance/variables.tf @@ -0,0 +1,204 @@ +variable "ibmcloud_api_key" { + description = "The IBM Cloud platform API key needed to deploy IAM enabled resources." + type = string + sensitive = true +} + +variable "powervs_zone" { + description = "IBM Cloud PowerVS zone." + type = string + validation { + condition = contains(["syd04", "syd05", "eu-de-1", "eu-de-2", "lon04", "lon06", "tok04", "us-east", "us-south", "dal10", "dal12", "dal14", "tor01", "osa21", "sao01", "sao04", "mon01", "wdc06", "wdc07", "che01", "mad02", "mad04", "wdc06-pvs-01"], var.powervs_zone) + error_message = "Only Following DC values are supported : syd04, syd05, eu-de-1, eu-de-2, lon04, lon06, tok04, us-east, us-south, dal10, dal12, dal14, tor01, osa21, sao01, sao04, mon01, wdc06, wdc07,che01, mad02, mad04, wdc06-pvs-01" + } +} + +variable "powervs_workspace_guid" { + description = "Existing GUID of the PowerVS workspace. The GUID of the service instance associated with an account." + type = string +} + +variable "powervs_ssh_public_key_name" { + description = "Name of the existing PowerVS SSH public key." + type = string +} + +##################################################### +# PowerVS Instance Parameters +##################################################### + +variable "powervs_instance_name" { + description = "Name of instance which will be created. Must be less than 13 characters." + type = string + validation { + condition = length(var.powervs_instance_name) < 13 + error_message = "The instance name must be less than 13 characters." + } +} + +variable "powervs_image_name" { + description = "Image name used for PowerVS instance. Run 'ibmcloud pi images' to list available images." + type = string +} + +variable "powervs_boot_image_storage_tier" { + description = "Storage type for server deployment. If storage type is not provided the storage type will default to tier3. Possible values tier0, tier1 and tier3" + type = string + default = null +} + +variable "powervs_hana_instance_sap_profile_id" { + description = "PowerVS SAP HANA instance profile to use. Must be one of the supported profiles. See [here](https://cloud.ibm.com/docs/sap?topic=sap-hana-iaas-offerings-profiles-power-vs). File system sizes are automatically calculated. Override automatic calculation by setting values in optional parameter 'powervs_hana_instance_custom_storage_config'." + type = string + default = "sh2-4x256" +} + +variable "powervs_server_type" { + description = "By default SAP profile will be deployed on default system type. Override this to specify the type of system on which to create the VM. Supported values are s922/e980/s1022/e1050/e1080/s1122/e1150/e1180. Mandatory when using dedicated hosts." + type = string + default = null +} + +variable "powervs_deployment_target" { + description = "The deployment of a dedicated host. Max items: 1, id is the uuid of the host group or host. type is the deployment target type, supported values are host and hostGroup" + type = list(object( + { + type = string + id = string + } + )) + default = null +} + +variable "powervs_networks" { + description = "Existing list of private subnet ids to be attached to an instance. The first element will become the primary interface. Run 'ibmcloud pi subnets' to list available subnets." + type = list( + object({ + name = string + id = string + cidr = optional(string) + }) + ) +} + +variable "powervs_hana_instance_custom_storage_config" { + description = "Custom file systems to be created and attached to PowerVS SAP HANA instance. 'size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the target mount point on OS." + type = list(object({ + name = string + size = string + count = string + tier = string + mount = string + pool = optional(string) + })) + default = [{ + "name" : "", + "size" : "", + "count" : "", + "tier" : "", + "mount" : "" + }] +} + +variable "powervs_hana_instance_additional_storage_config" { + description = "Additional File systems to be created and attached to PowerVS SAP HANA instance. 'size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the target mount point on OS." + type = list(object({ + name = string + size = string + count = string + tier = string + mount = string + })) + default = [{ + "name" : "usrsap", + "size" : "50", + "count" : "1", + "tier" : "tier3", + "mount" : "/usr/sap" + + }] +} + +##################################################### +# PowerVS Instance Initialization Optional parameters. +##################################################### + +variable "powervs_instance_init_linux" { + description = "Configures a PowerVS linux instance to have internet access by setting proxy on it, updates os and create filesystems using ansible collection [ibm.power_linux_sap collection](https://galaxy.ansible.com/ui/repo/published/ibm/power_linux_sap/). where 'proxy_host_or_ip_port' E.g., 10.10.10.4:3128 , 'bastion_host_ip' is public IP of bastion/jump host to access the private IP of created linux PowerVS instance." + sensitive = true + type = object( + { + enable = bool + bastion_host_ip = string + ansible_host_or_ip = string + } + ) + + default = { + enable = false + bastion_host_ip = "" + ansible_host_or_ip = "" + } + validation { + condition = var.powervs_instance_init_linux.enable == false || (var.powervs_instance_init_linux.enable == true && length(var.powervs_instance_init_linux.bastion_host_ip) > 0 && length(var.powervs_instance_init_linux.ansible_host_or_ip) > 0) + error_message = "bastion_host_ip and ansible_host_or_ip must be provided when powervs_instance_init_linux is enabled." + } +} + +variable "ssh_private_key" { + description = "SSH private key to access the PowerVS instance via bastion host." + type = string + sensitive = true + default = "" + + validation { + condition = var.powervs_instance_init_linux.enable == false || (var.powervs_instance_init_linux.enable == true && length(var.ssh_private_key) > 0) + error_message = "ssh_private_key must be provided when powervs_instance_init_linux is enabled." + } + +} +variable "powervs_network_services_config" { + description = "Configures network services NTP, NFS and DNS on PowerVS instance. Requires 'powervs_instance_init_linux' to be specified as internet access is required to download ansible collection [ibm.power_linux_sap collection](https://galaxy.ansible.com/ui/repo/published/ibm/power_linux_sap/) to configure these services. The 'opts' attribute can take in comma separated values." + type = object( + { + squid = object({ enable = bool, squid_server_ip_port = string, no_proxy_hosts = string }) + nfs = object({ enable = bool, nfs_server_path = string, nfs_client_path = string, opts = string, fstype = string }) + dns = object({ enable = bool, dns_server_ip = string }) + ntp = object({ enable = bool, ntp_server_ip = string }) + } + ) + + default = { + squid = { enable = false, squid_server_ip_port = "", no_proxy_hosts = "" } + nfs = { enable = false, nfs_server_path = "", nfs_client_path = "", opts = "", fstype = "" } + ntp = { enable = false, ntp_server_ip = "" }, + dns = { enable = false, dns_server_ip = "" } + } + +} + +variable "sap_domain" { + description = "SAP network domain name." + type = string + default = "sap.com" +} + +variable "powervs_os_registration_username" { + description = "If you're using a byol or a custom RHEL/SLES image for SAP HANA and Netweaver you need to provide your OS registration credentials here. Leave empty if you're using an IBM provided subscription (FLS)." + type = string + default = null +} + +variable "powervs_os_registration_password" { + description = "If you're using a byol or a custom RHEL/SLES image for SAP HANA and Netweaver you need to provide your OS registration credentials here. Leave empty if you're using an IBM provided subscription (FLS)." + type = string + sensitive = true + default = null +} + +variable "ansible_vault_password" { + description = "Vault password to encrypt ansible playbooks that contain sensitive information. Required with customer provided linux subscription (powervs_os_registration). Password requirements: 15-100 characters and at least one uppercase letter, one lowercase letter, one number, and one special character. Allowed characters: A-Z, a-z, 0-9, !#$%&()*+-.:;<=>?@[]_{|}~." + type = string + sensitive = true + default = null +} diff --git a/solutions/single-hana-instance/version.tf b/solutions/single-hana-instance/version.tf new file mode 100644 index 00000000..98e8f099 --- /dev/null +++ b/solutions/single-hana-instance/version.tf @@ -0,0 +1,13 @@ +##################################################### +# PowerVS Instance Module +##################################################### + +terraform { + required_version = ">= 1.9.0" + required_providers { + ibm = { + source = "IBM-Cloud/ibm" + version = "=1.83.3" + } + } +} diff --git a/solutions/single-netweaver-instance/README.md b/solutions/single-netweaver-instance/README.md new file mode 100644 index 00000000..410ce78f --- /dev/null +++ b/solutions/single-netweaver-instance/README.md @@ -0,0 +1,67 @@ +# Provisioning a single tuned Power Virtual Server for SAP Application Server + +This example deploys a single Power Virtual Server instance that is tuned and ready to host an SAP NetWeaver/Application Server. + +It provisions the following components in IBM Cloud: + +* Creates an IBM® Power Virtual Server instance in an existing PowerVS workspace (which contains a public SSH key, pre-existing subnet and a pre-imported OS image). +* Creates and attaches volumes to the instance. +* (Optional) Initializes the instance by configuring proxy settings, network services (NTP, DNS, NFS), and creating file systems. +* (Optional) Tunes the OS for SAP NetWeaver/SAP Application Server. +* Supports bring-your-own-license (BYOL) for RHEL/SLES images. +* Does **not** install SAP NetWeaver/SAP Application Server. + + + +### Requirements + +| Name | Version | +|------|---------| +| [terraform](#requirement\_terraform) | >= 1.9.0 | +| [ibm](#requirement\_ibm) | =1.83.3 | + +### Modules + +| Name | Source | Version | +|------|--------|---------| +| [configure\_os\_for\_sap](#module\_configure\_os\_for\_sap) | ../../modules/ansible | n/a | +| [sap\_netweaver\_instance](#module\_sap\_netweaver\_instance) | terraform-ibm-modules/powervs-instance/ibm | 2.8.2 | + +### Resources + +No resources. + +### Inputs + +| Name | Description | Type | Default | Required | +|------|-------------|------|---------|:--------:| +| [ansible\_vault\_password](#input\_ansible\_vault\_password) | Vault password to encrypt ansible playbooks that contain sensitive information. Required with customer provided linux subscription (powervs\_os\_registration). Password requirements: 15-100 characters and at least one uppercase letter, one lowercase letter, one number, and one special character. Allowed characters: A-Z, a-z, 0-9, !#$%&()*+-.:;<=>?@[]\_{\|}~. | `string` | `null` | no | +| [ibmcloud\_api\_key](#input\_ibmcloud\_api\_key) | The IBM Cloud platform API key needed to deploy IAM enabled resources. | `string` | n/a | yes | +| [powervs\_boot\_image\_storage\_tier](#input\_powervs\_boot\_image\_storage\_tier) | Storage type for server deployment. If storage type is not provided the storage type will default to tier3. Possible values tier0, tier1 and tier3 | `string` | `null` | no | +| [powervs\_cpu\_proc\_type](#input\_powervs\_cpu\_proc\_type) | The type of processor mode in which the VM will run with shared, capped or dedicated. | `string` | n/a | yes | +| [powervs\_deployment\_target](#input\_powervs\_deployment\_target) | The deployment of a dedicated host. Max items: 1, id is the uuid of the host group or host. type is the deployment target type, supported values are host and hostGroup |
list(object(
{
type = string
id = string
}
))
| `null` | no | +| [powervs\_image\_name](#input\_powervs\_image\_name) | Image name used for PowerVS instance. Run 'ibmcloud pi images' to list available images. | `string` | n/a | yes | +| [powervs\_instance\_init\_linux](#input\_powervs\_instance\_init\_linux) | Configures a PowerVS linux instance to have internet access by setting proxy on it, updates os and create filesystems using ansible collection [ibm.power\_linux\_sap collection](https://galaxy.ansible.com/ui/repo/published/ibm/power_linux_sap/). where 'proxy\_host\_or\_ip\_port' E.g., 10.10.10.4:3128 , 'bastion\_host\_ip' is public IP of bastion/jump host to access the private IP of created linux PowerVS instance. |
object(
{
enable = bool
bastion_host_ip = string
ansible_host_or_ip = string
}
)
|
{
"ansible_host_or_ip": "",
"bastion_host_ip": "",
"enable": false
}
| no | +| [powervs\_instance\_name](#input\_powervs\_instance\_name) | Name of instance which will be created. Must be less than 13 characters. | `string` | n/a | yes | +| [powervs\_memory\_size](#input\_powervs\_memory\_size) | The amount of memory that you want to assign to your instance in GB. | `string` | n/a | yes | +| [powervs\_network\_services\_config](#input\_powervs\_network\_services\_config) | Configures network services NTP, NFS and DNS on PowerVS instance. Requires 'powervs\_instance\_init\_linux' to be specified as internet access is required to download ansible collection [ibm.power\_linux\_sap collection](https://galaxy.ansible.com/ui/repo/published/ibm/power_linux_sap/) to configure these services. The 'opts' attribute can take in comma separated values. |
object(
{
squid = object({ enable = bool, squid_server_ip_port = string, no_proxy_hosts = string })
nfs = object({ enable = bool, nfs_server_path = string, nfs_client_path = string, opts = string, fstype = string })
dns = object({ enable = bool, dns_server_ip = string })
ntp = object({ enable = bool, ntp_server_ip = string })
}
)
|
{
"dns": {
"dns_server_ip": "",
"enable": false
},
"nfs": {
"enable": false,
"fstype": "",
"nfs_client_path": "",
"nfs_server_path": "",
"opts": ""
},
"ntp": {
"enable": false,
"ntp_server_ip": ""
},
"squid": {
"enable": false,
"no_proxy_hosts": "",
"squid_server_ip_port": ""
}
}
| no | +| [powervs\_networks](#input\_powervs\_networks) | Existing list of private subnet ids to be attached to an instance. The first element will become the primary interface. Run 'ibmcloud pi subnets' to list available subnets. |
list(
object({
name = string
id = string
cidr = optional(string)
})
)
| n/a | yes | +| [powervs\_number\_of\_processors](#input\_powervs\_number\_of\_processors) | The number of vCPUs to assign to the VM as visible within the guest Operating System. | `string` | n/a | yes | +| [powervs\_os\_registration\_password](#input\_powervs\_os\_registration\_password) | If you're using a byol or a custom RHEL/SLES image for SAP HANA and Netweaver you need to provide your OS registration credentials here. Leave empty if you're using an IBM provided subscription (FLS). | `string` | `null` | no | +| [powervs\_os\_registration\_username](#input\_powervs\_os\_registration\_username) | If you're using a byol or a custom RHEL/SLES image for SAP HANA and Netweaver you need to provide your OS registration credentials here. Leave empty if you're using an IBM provided subscription (FLS). | `string` | `null` | no | +| [powervs\_server\_type](#input\_powervs\_server\_type) | The type of system on which to create the VM. Supported values are s922/e980/s1022/e1050/e1080/s1122/e1150/e1180. | `string` | n/a | yes | +| [powervs\_ssh\_public\_key\_name](#input\_powervs\_ssh\_public\_key\_name) | Name of the existing PowerVS SSH public key. | `string` | n/a | yes | +| [powervs\_storage\_config](#input\_powervs\_storage\_config) | File systems to be created and attached to PowerVS instance. 'disk\_size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the mount point on the OS. 'pool' specifies the volume pool where the volume will be created. 'sharable' specifies if volume can be shared across PVM instances. |
list(object({
name = string
size = string
count = string
tier = string
mount = optional(string)
pool = optional(string)
sharable = optional(bool)
}))
|
[
{
"count": "1",
"mount": "/usr/sap",
"name": "usrsap",
"size": "200",
"tier": "tier3"
},
{
"count": "1",
"mount": "/sapmnt",
"name": "sapmnt",
"size": "200",
"tier": "tier3"
}
]
| no | +| [powervs\_workspace\_guid](#input\_powervs\_workspace\_guid) | Existing GUID of the PowerVS workspace. The GUID of the service instance associated with an account. | `string` | n/a | yes | +| [powervs\_zone](#input\_powervs\_zone) | IBM Cloud PowerVS zone. | `string` | n/a | yes | +| [sap\_domain](#input\_sap\_domain) | SAP network domain name. | `string` | `"sap.com"` | no | +| [ssh\_private\_key](#input\_ssh\_private\_key) | SSH private key to access the PowerVS instance via bastion host. | `string` | `""` | no | + +### Outputs + +| Name | Description | +|------|-------------| +| [pi\_instance\_primary\_ip](#output\_pi\_instance\_primary\_ip) | IP address of the primary network interface of IBM PowerVS instance. | +| [pi\_instance\_private\_ips](#output\_pi\_instance\_private\_ips) | All private IP addresses (as a list) of IBM PowerVS instance. | +| [pi\_storage\_configuration](#output\_pi\_storage\_configuration) | Storage configuration of PowerVS instance. | + diff --git a/solutions/single-netweaver-instance/main.tf b/solutions/single-netweaver-instance/main.tf new file mode 100644 index 00000000..33375ccc --- /dev/null +++ b/solutions/single-netweaver-instance/main.tf @@ -0,0 +1,63 @@ +##################################################### +# Deploy PowerVS Instance +##################################################### + +module "sap_netweaver_instance" { + source = "terraform-ibm-modules/powervs-instance/ibm" + version = "2.8.2" + + + pi_workspace_guid = var.powervs_workspace_guid + pi_ssh_public_key_name = var.powervs_ssh_public_key_name + pi_image_id = var.powervs_image_name + pi_instance_name = var.powervs_instance_name + pi_boot_image_storage_tier = var.powervs_boot_image_storage_tier + pi_sap_profile_id = null + pi_server_type = var.powervs_server_type + pi_deployment_target = var.powervs_deployment_target + pi_cpu_proc_type = var.powervs_cpu_proc_type + pi_number_of_processors = var.powervs_number_of_processors + pi_memory_size = var.powervs_memory_size + pi_networks = var.powervs_networks + pi_storage_config = var.powervs_storage_config + ansible_vault_password = var.ansible_vault_password + pi_instance_init_linux = merge(var.powervs_instance_init_linux, + { + ssh_private_key = var.ssh_private_key, + custom_os_registration = ( + try(trim(var.powervs_os_registration_username), "") != "" && + try(trim(var.powervs_os_registration_password), "") != "" + ) ? { + username = var.powervs_os_registration_username + password = var.powervs_os_registration_password + } : null + + }) + pi_network_services_config = var.powervs_network_services_config +} + +module "configure_os_for_sap" { + + source = "../../modules/ansible" + depends_on = [module.sap_netweaver_instance] + count = var.powervs_instance_init_linux.enable ? 1 : 0 + + bastion_host_ip = var.powervs_instance_init_linux.bastion_host_ip + ansible_host_or_ip = var.powervs_instance_init_linux.ansible_host_or_ip + ssh_private_key = var.ssh_private_key + configure_ansible_host = true + + src_script_template_name = "configure-os-for-sap/ansible_exec.sh.tftpl" + dst_script_file_name = "${var.powervs_instance_name}_configure_os_for_sap.sh" + + src_playbook_template_name = "configure-os-for-sap/playbook-configure-os-for-sap.yml.tftpl" + dst_playbook_file_name = "${var.powervs_instance_name}-playbook-configure-os-for-sap.yml" + playbook_template_vars = { + "sap_solution" : "NETWEAVER", + "sap_domain" : var.sap_domain + } + + src_inventory_template_name = "pi-instance-inventory.tftpl" + dst_inventory_file_name = "${var.powervs_instance_name}-instance-inventory" + inventory_template_vars = { "pi_instance_management_ip" : module.sap_netweaver_instance.pi_instance_primary_ip } +} diff --git a/solutions/single-netweaver-instance/outputs.tf b/solutions/single-netweaver-instance/outputs.tf new file mode 100644 index 00000000..eed13770 --- /dev/null +++ b/solutions/single-netweaver-instance/outputs.tf @@ -0,0 +1,16 @@ +############################################################################## +# Outputs +output "pi_instance_primary_ip" { + description = "IP address of the primary network interface of IBM PowerVS instance." + value = module.sap_netweaver_instance.pi_instance_primary_ip +} + +output "pi_instance_private_ips" { + description = "All private IP addresses (as a list) of IBM PowerVS instance." + value = module.sap_netweaver_instance.pi_instance_private_ips +} + +output "pi_storage_configuration" { + description = "Storage configuration of PowerVS instance." + value = module.sap_netweaver_instance.pi_storage_configuration +} diff --git a/solutions/single-netweaver-instance/provider.tf b/solutions/single-netweaver-instance/provider.tf new file mode 100644 index 00000000..bf95131c --- /dev/null +++ b/solutions/single-netweaver-instance/provider.tf @@ -0,0 +1,33 @@ +locals { + ibm_powervs_zone_region_map = { + "syd04" = "syd" + "syd05" = "syd" + "sao01" = "sao" + "sao04" = "sao" + "tor01" = "tor" + "mon01" = "mon" + "eu-de-1" = "eu-de" + "eu-de-2" = "eu-de" + "mad02" = "mad" + "mad04" = "mad" + "lon04" = "lon" + "lon06" = "lon" + "osa21" = "osa" + "tok04" = "tok" + "us-south" = "us-south" + "dal10" = "us-south" + "dal12" = "us-south" + "dal14" = "us-south" + "us-east" = "us-east" + "wdc06" = "us-east" + "wdc07" = "us-east" + "wdc06-pvs-01" = "us-east" + } + +} + +provider "ibm" { + region = lookup(local.ibm_powervs_zone_region_map, var.powervs_zone, null) + zone = var.powervs_zone + ibmcloud_api_key = var.ibmcloud_api_key != null ? var.ibmcloud_api_key : null +} diff --git a/solutions/single-netweaver-instance/variables.tf b/solutions/single-netweaver-instance/variables.tf new file mode 100644 index 00000000..eed49a34 --- /dev/null +++ b/solutions/single-netweaver-instance/variables.tf @@ -0,0 +1,195 @@ +variable "ibmcloud_api_key" { + description = "The IBM Cloud platform API key needed to deploy IAM enabled resources." + type = string + sensitive = true +} + +variable "powervs_zone" { + description = "IBM Cloud PowerVS zone." + type = string + validation { + condition = contains(["syd04", "syd05", "eu-de-1", "eu-de-2", "lon04", "lon06", "tok04", "us-east", "us-south", "dal10", "dal12", "dal14", "tor01", "osa21", "sao01", "sao04", "mon01", "wdc06", "wdc07", "che01", "mad02", "mad04", "wdc06-pvs-01"], var.powervs_zone) + error_message = "Only Following DC values are supported : syd04, syd05, eu-de-1, eu-de-2, lon04, lon06, tok04, us-east, us-south, dal10, dal12, dal14, tor01, osa21, sao01, sao04, mon01, wdc06, wdc07,che01, mad02, mad04, wdc06-pvs-01" + } +} + +variable "powervs_workspace_guid" { + description = "Existing GUID of the PowerVS workspace. The GUID of the service instance associated with an account." + type = string +} + +variable "powervs_ssh_public_key_name" { + description = "Name of the existing PowerVS SSH public key." + type = string +} + +##################################################### +# PowerVS Instance Parameters +##################################################### + +variable "powervs_instance_name" { + description = "Name of instance which will be created. Must be less than 13 characters." + type = string + validation { + condition = length(var.powervs_instance_name) < 13 + error_message = "The instance name must be less than 13 characters." + } +} + +variable "powervs_image_name" { + description = "Image name used for PowerVS instance. Run 'ibmcloud pi images' to list available images." + type = string +} + +variable "powervs_boot_image_storage_tier" { + description = "Storage type for server deployment. If storage type is not provided the storage type will default to tier3. Possible values tier0, tier1 and tier3" + type = string + default = null +} + +variable "powervs_server_type" { + description = "The type of system on which to create the VM. Supported values are s922/e980/s1022/e1050/e1080/s1122/e1150/e1180." + type = string +} + +variable "powervs_deployment_target" { + description = "The deployment of a dedicated host. Max items: 1, id is the uuid of the host group or host. type is the deployment target type, supported values are host and hostGroup" + type = list(object( + { + type = string + id = string + } + )) + default = null +} + +variable "powervs_cpu_proc_type" { + description = "The type of processor mode in which the VM will run with shared, capped or dedicated." + type = string +} + +variable "powervs_number_of_processors" { + description = "The number of vCPUs to assign to the VM as visible within the guest Operating System." + type = string +} + +variable "powervs_memory_size" { + description = "The amount of memory that you want to assign to your instance in GB." + type = string +} + +variable "powervs_networks" { + description = "Existing list of private subnet ids to be attached to an instance. The first element will become the primary interface. Run 'ibmcloud pi subnets' to list available subnets." + type = list( + object({ + name = string + id = string + cidr = optional(string) + }) + ) +} + +variable "powervs_storage_config" { + description = "File systems to be created and attached to PowerVS instance. 'disk_size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the mount point on the OS. 'pool' specifies the volume pool where the volume will be created. 'sharable' specifies if volume can be shared across PVM instances." + type = list(object({ + name = string + size = string + count = string + tier = string + mount = optional(string) + pool = optional(string) + sharable = optional(bool) + })) + default = [ + { + name = "usrsap", size = "200", count = "1", tier = "tier3", mount = "/usr/sap" + }, + { + name = "sapmnt", size = "200", count = "1", tier = "tier3", mount = "/sapmnt" + } + ] +} + +##################################################### +# PowerVS Instance Initialization Optional parameters. +##################################################### + +variable "powervs_instance_init_linux" { + description = "Configures a PowerVS linux instance to have internet access by setting proxy on it, updates os and create filesystems using ansible collection [ibm.power_linux_sap collection](https://galaxy.ansible.com/ui/repo/published/ibm/power_linux_sap/). where 'proxy_host_or_ip_port' E.g., 10.10.10.4:3128 , 'bastion_host_ip' is public IP of bastion/jump host to access the private IP of created linux PowerVS instance." + sensitive = true + type = object( + { + enable = bool + bastion_host_ip = string + ansible_host_or_ip = string + } + ) + + default = { + enable = false + bastion_host_ip = "" + ansible_host_or_ip = "" + } + validation { + condition = var.powervs_instance_init_linux.enable == false || (var.powervs_instance_init_linux.enable == true && length(var.powervs_instance_init_linux.bastion_host_ip) > 0 && length(var.powervs_instance_init_linux.ansible_host_or_ip) > 0) + error_message = "bastion_host_ip and ansible_host_or_ip must be provided when powervs_instance_init_linux is enabled." + } +} + +variable "ssh_private_key" { + description = "SSH private key to access the PowerVS instance via bastion host." + type = string + sensitive = true + default = "" + + validation { + condition = var.powervs_instance_init_linux.enable == false || (var.powervs_instance_init_linux.enable == true && length(var.ssh_private_key) > 0) + error_message = "ssh_private_key must be provided when powervs_instance_init_linux is enabled." + } + +} +variable "powervs_network_services_config" { + description = "Configures network services NTP, NFS and DNS on PowerVS instance. Requires 'powervs_instance_init_linux' to be specified as internet access is required to download ansible collection [ibm.power_linux_sap collection](https://galaxy.ansible.com/ui/repo/published/ibm/power_linux_sap/) to configure these services. The 'opts' attribute can take in comma separated values." + type = object( + { + squid = object({ enable = bool, squid_server_ip_port = string, no_proxy_hosts = string }) + nfs = object({ enable = bool, nfs_server_path = string, nfs_client_path = string, opts = string, fstype = string }) + dns = object({ enable = bool, dns_server_ip = string }) + ntp = object({ enable = bool, ntp_server_ip = string }) + } + ) + + default = { + squid = { enable = false, squid_server_ip_port = "", no_proxy_hosts = "" } + nfs = { enable = false, nfs_server_path = "", nfs_client_path = "", opts = "", fstype = "" } + ntp = { enable = false, ntp_server_ip = "" }, + dns = { enable = false, dns_server_ip = "" } + } + +} + +variable "sap_domain" { + description = "SAP network domain name." + type = string + default = "sap.com" +} + +variable "powervs_os_registration_username" { + description = "If you're using a byol or a custom RHEL/SLES image for SAP HANA and Netweaver you need to provide your OS registration credentials here. Leave empty if you're using an IBM provided subscription (FLS)." + type = string + default = null +} + +variable "powervs_os_registration_password" { + description = "If you're using a byol or a custom RHEL/SLES image for SAP HANA and Netweaver you need to provide your OS registration credentials here. Leave empty if you're using an IBM provided subscription (FLS)." + type = string + sensitive = true + default = null +} + +variable "ansible_vault_password" { + description = "Vault password to encrypt ansible playbooks that contain sensitive information. Required with customer provided linux subscription (powervs_os_registration). Password requirements: 15-100 characters and at least one uppercase letter, one lowercase letter, one number, and one special character. Allowed characters: A-Z, a-z, 0-9, !#$%&()*+-.:;<=>?@[]_{|}~." + type = string + sensitive = true + default = null +} diff --git a/solutions/single-netweaver-instance/version.tf b/solutions/single-netweaver-instance/version.tf new file mode 100644 index 00000000..98e8f099 --- /dev/null +++ b/solutions/single-netweaver-instance/version.tf @@ -0,0 +1,13 @@ +##################################################### +# PowerVS Instance Module +##################################################### + +terraform { + required_version = ">= 1.9.0" + required_providers { + ibm = { + source = "IBM-Cloud/ibm" + version = "=1.83.3" + } + } +} From 13ac73ec78611ef44cd72ffd84fa8c0396a1f1a6 Mon Sep 17 00:00:00 2001 From: surajsbharadwaj Date: Sat, 11 Oct 2025 17:30:36 +0200 Subject: [PATCH 2/7] chore: new solutions update Readme --- README.md | 19 +++++++++++-------- .../ibm-catalog/sap-ready-to-go/README.md | 2 +- 2 files changed, 12 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index 5320f984..e9451e35 100644 --- a/README.md +++ b/README.md @@ -16,26 +16,30 @@ This repository contains deployable architecture solutions that help in deployin - Creates and configures **one HANA instance and zero to several NetWeaver instances** with **RHEL or SLES OS** distribution. Creates a private subnet for SAP communication for the entire landscape. - Optionally configures OS network management services (NTP, NFS, and DNS services) using Ansible Galaxy Collection from [IBM](https://galaxy.ansible.com/ui/repo/published/ibm/power_linux_sap/): `power_linux_sap` - Additionally tunes the instances according to SAP's best practices, which are fully ready for hosting SAP applications. -2. [IBM catalog PowerVS S/4HANA or BW/4HANA variation](https://github.com/terraform-ibm-modules/terraform-ibm-powervs-sap/tree/main/solutions/ibm-catalog/sap-s4hana-bw4hana) + +1. [IBM catalog PowerVS S/4HANA or BW/4HANA variation](https://github.com/terraform-ibm-modules/terraform-ibm-powervs-sap/tree/main/solutions/ibm-catalog/sap-s4hana-bw4hana) - Creates and configures **one HANA instance and one NetWeaver instance** with **RHEL** OS distribution. Creates a private subnet for SAP communication for the entire landscape. - Optionally configures OS network management services (NTP, NFS, and DNS services) using Ansible Galaxy Collection from [IBM](https://galaxy.ansible.com/ui/repo/published/ibm/power_linux_sap/): `power_linux_sap` - Tunes the instances according to SAP's best practices. - Downloads user-provided preloaded SAP Installation binaries from IBM Cloud Object Storage Bucket. - Installs and configures **SAP applications** (SAP HANA DB, SAP S4/HANA, SAP BW4/HANA) using [RHEL System Roles](https://access.redhat.com/articles/4488731): `sap_hana_install`, `sap_swpm`,`sap_general_preconfigure`, `sap_hana_preconfigure`, `sap_netweaver_preconfigure` +1. [Single HANA Instance](https://github.com/terraform-ibm-modules/terraform-ibm-powervs-sap/tree/main/solutions/single-hana-instance) + - Creates a single HANA instance based on HANA certified profiles along with right storage config. + - Optionally configures OS network management services (NTP, NFS, and DNS services) using Ansible Galaxy Collection from [IBM](https://galaxy.ansible.com/ui/repo/published/ibm/power_linux_sap/): `power_linux_sap` + - Tunes the instances according to SAP's best practices. -### Solutions independent of IBM Cloud prerequisite Schematics workspace ID: -1. [PowerVS SAP Ready variation](https://github.com/terraform-ibm-modules/terraform-ibm-powervs-sap/tree/main/solutions/sap-ready-to-go) - - Creates and configures **one HANA instance and zero to several NetWeaver instances** with **RHEL or SLES OS** distribution. Creates a private subnet for SAP communication for the entire landscape - - Optionally configures OS network management services (NTP, NFS, and DNS services) using Ansible Galaxy collection from [IBM](https://galaxy.ansible.com/ui/repo/published/ibm/power_linux_sap/) - - Additionally tunes the instances according to SAP's best practices, which is fully ready for hosting SAP applications. +1. [Single Netweaver Instance](https://github.com/terraform-ibm-modules/terraform-ibm-powervs-sap/tree/main/solutions/single-netweaver-instance) + - Creates a single Netweaver instance along with right storage config. + - Optionally configures OS network management services (NTP, NFS, and DNS services) using Ansible Galaxy Collection from [IBM](https://galaxy.ansible.com/ui/repo/published/ibm/power_linux_sap/): `power_linux_sap` + - Tunes the instances according to SAP's best practices. ## Reference architectures - [IBM catalog PowerVS SAP Ready variation](https://github.com/terraform-ibm-modules/terraform-ibm-powervs-sap/blob/main/reference-architectures/sap-ready-to-go/deploy-arch-ibm-pvs-sap-ready-to-go.svg) - [IBM catalog PowerVS SAP S/4HANA or BW/4HANA variation](https://github.com/terraform-ibm-modules/terraform-ibm-powervs-sap/blob/main/reference-architectures/sap-s4hana-bw4hana/deploy-arch-ibm-pvs-sap-s4hana-bw4hana.svg) -- [Power Virtual Server with vpc landing zone](https://github.com/terraform-ibm-modules/terraform-ibm-powervs-infrastructure/blob/main/reference-architectures/full-stack/deploy-arch-ibm-pvs-inf-full-stack.svg) + ## Solutions @@ -44,7 +48,6 @@ This repository contains deployable architecture solutions that help in deployin |:---------------------------------------------------------------------------:|:------------------------:|:-------------------------------------:|:-----------------------------:|:----------------------------:|:--------------------------:|:---------------------------:|:--------------------:| | [IBM catalog PowerVS SAP Ready]( ./solutions/ibm-catalog/sap-ready-to-go/ ) | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | 1 | 0 to N | :heavy_check_mark: | :heavy_check_mark: | N/A | | [IBM catalog SAP S/4HANA or BW/4HANA variation]( ./solutions/ibm-catalog/sap-s4hana-bw4hana ) | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | 1 | 1 | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | -| [PowerVS SAP Ready]( ./solutions/sap-ready-to-go/ ) | N/A | N/A | :heavy_check_mark: | 1 | 0 to N | :heavy_check_mark: | :heavy_check_mark: | N/A | diff --git a/solutions/ibm-catalog/sap-ready-to-go/README.md b/solutions/ibm-catalog/sap-ready-to-go/README.md index 20d031bf..73f2551b 100644 --- a/solutions/ibm-catalog/sap-ready-to-go/README.md +++ b/solutions/ibm-catalog/sap-ready-to-go/README.md @@ -41,7 +41,7 @@ - Optionally configures a shared NFS directory on all created PowerVS instances. - Optionally installs Sysdig agent and configures connection to [IBM Cloud Security and Compliance Center Workload Protection](https://cloud.ibm.com/docs/workload-protection) - Post-instance provisioning, Ansible Galaxy collection roles from [IBM](https://galaxy.ansible.com/ui/repo/published/ibm/power_linux_sap/) are executed: `power_linux_sap`. -- Tested with RHEL8.4,/8.6/8.8/9.2, SLES15-SP3/SP5 images. +- Tested with RHEL8.4,/8.6/8.8/9.2/9.4, SLES15-SP3/SP5/SP6 images. ## Notes From f75d9339d83ceaf00a98a22614f83054ad313b22 Mon Sep 17 00:00:00 2001 From: surajsbharadwaj Date: Sat, 11 Oct 2025 17:33:46 +0200 Subject: [PATCH 3/7] docs: update Readme --- README.md | 5 +++-- solutions/single-hana-instance/README.md | 3 --- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index e9451e35..ca98e828 100644 --- a/README.md +++ b/README.md @@ -7,10 +7,11 @@ [![Renovate enabled](https://img.shields.io/badge/renovate-enabled-brightgreen.svg)](https://renovatebot.com/) ## Summary -This repository contains deployable architecture solutions that help in deploying VPC landing zones, Power Virtual Server workspaces, and SAP HANA solutions. The solutions are available in the IBM Cloud Catalog and can also be deployed without the catalog, except for a few solutions. +This repository contains deployable architecture solutions that help in deploying VPC landing zones, Power Virtual Server workspaces, and SAP HANA solutions. The solutions are available in the IBM Cloud Catalog and can also be deployed without the catalog. -### IBM catalog solutions that require a Schematics workspace ID of [Power Virtual Server with VPC landing zone](https://cloud.ibm.com/catalog/architecture/deploy-arch-ibm-pvs-inf-2dd486c7-b317-4aaa-907b-42671485ad96-global) +### Solutions + 1. [IBM catalog PowerVS SAP Ready variation](https://github.com/terraform-ibm-modules/terraform-ibm-powervs-sap/tree/main/solutions/ibm-catalog/sap-ready-to-go) - Creates a VPC and Power Virtual Server workspace, interconnects them, and configures OS network management services (SQUID proxy, NTP, NFS, and DNS) using Ansible Galaxy collection roles from the ibm.power_linux_sap collection. - Creates and configures **one HANA instance and zero to several NetWeaver instances** with **RHEL or SLES OS** distribution. Creates a private subnet for SAP communication for the entire landscape. diff --git a/solutions/single-hana-instance/README.md b/solutions/single-hana-instance/README.md index 25a21861..d07d1999 100644 --- a/solutions/single-hana-instance/README.md +++ b/solutions/single-hana-instance/README.md @@ -13,9 +13,6 @@ It provisions the following components in IBM Cloud: * Supports bring-your-own-license (BYOL) for RHEL/SLES images. * Does **not** install SAP HANA. ---- - -Would you like me to **combine both SAP Application Server and HANA** into a single doc (with separate sections), or keep them as two standalone docs? From 09e6d74b196ce63fbc3afb8613c2dcf374d057ea Mon Sep 17 00:00:00 2001 From: surajsbharadwaj Date: Sun, 12 Oct 2025 21:49:43 +0200 Subject: [PATCH 4/7] fix: defaults for ansible vault --- solutions/single-hana-instance/README.md | 2 +- solutions/single-hana-instance/variables.tf | 2 +- solutions/single-netweaver-instance/README.md | 2 +- solutions/single-netweaver-instance/variables.tf | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/solutions/single-hana-instance/README.md b/solutions/single-hana-instance/README.md index d07d1999..a464025e 100644 --- a/solutions/single-hana-instance/README.md +++ b/solutions/single-hana-instance/README.md @@ -39,7 +39,7 @@ No resources. | Name | Description | Type | Default | Required | |------|-------------|------|---------|:--------:| -| [ansible\_vault\_password](#input\_ansible\_vault\_password) | Vault password to encrypt ansible playbooks that contain sensitive information. Required with customer provided linux subscription (powervs\_os\_registration). Password requirements: 15-100 characters and at least one uppercase letter, one lowercase letter, one number, and one special character. Allowed characters: A-Z, a-z, 0-9, !#$%&()*+-.:;<=>?@[]\_{\|}~. | `string` | `null` | no | +| [ansible\_vault\_password](#input\_ansible\_vault\_password) | Vault password to encrypt ansible playbooks that contain sensitive information. Required with customer provided linux subscription (powervs\_os\_registration). Password requirements: 15-100 characters and at least one uppercase letter, one lowercase letter, one number, and one special character. Allowed characters: A-Z, a-z, 0-9, !#$%&()*+-.:;<=>?@[]\_{\|}~. | `string` | `""` | no | | [ibmcloud\_api\_key](#input\_ibmcloud\_api\_key) | The IBM Cloud platform API key needed to deploy IAM enabled resources. | `string` | n/a | yes | | [powervs\_boot\_image\_storage\_tier](#input\_powervs\_boot\_image\_storage\_tier) | Storage type for server deployment. If storage type is not provided the storage type will default to tier3. Possible values tier0, tier1 and tier3 | `string` | `null` | no | | [powervs\_deployment\_target](#input\_powervs\_deployment\_target) | The deployment of a dedicated host. Max items: 1, id is the uuid of the host group or host. type is the deployment target type, supported values are host and hostGroup |
list(object(
{
type = string
id = string
}
))
| `null` | no | diff --git a/solutions/single-hana-instance/variables.tf b/solutions/single-hana-instance/variables.tf index 9bb78977..d52d5af2 100644 --- a/solutions/single-hana-instance/variables.tf +++ b/solutions/single-hana-instance/variables.tf @@ -200,5 +200,5 @@ variable "ansible_vault_password" { description = "Vault password to encrypt ansible playbooks that contain sensitive information. Required with customer provided linux subscription (powervs_os_registration). Password requirements: 15-100 characters and at least one uppercase letter, one lowercase letter, one number, and one special character. Allowed characters: A-Z, a-z, 0-9, !#$%&()*+-.:;<=>?@[]_{|}~." type = string sensitive = true - default = null + default = "" } diff --git a/solutions/single-netweaver-instance/README.md b/solutions/single-netweaver-instance/README.md index 410ce78f..236a2ee9 100644 --- a/solutions/single-netweaver-instance/README.md +++ b/solutions/single-netweaver-instance/README.md @@ -35,7 +35,7 @@ No resources. | Name | Description | Type | Default | Required | |------|-------------|------|---------|:--------:| -| [ansible\_vault\_password](#input\_ansible\_vault\_password) | Vault password to encrypt ansible playbooks that contain sensitive information. Required with customer provided linux subscription (powervs\_os\_registration). Password requirements: 15-100 characters and at least one uppercase letter, one lowercase letter, one number, and one special character. Allowed characters: A-Z, a-z, 0-9, !#$%&()*+-.:;<=>?@[]\_{\|}~. | `string` | `null` | no | +| [ansible\_vault\_password](#input\_ansible\_vault\_password) | Vault password to encrypt ansible playbooks that contain sensitive information. Required with customer provided linux subscription (powervs\_os\_registration). Password requirements: 15-100 characters and at least one uppercase letter, one lowercase letter, one number, and one special character. Allowed characters: A-Z, a-z, 0-9, !#$%&()*+-.:;<=>?@[]\_{\|}~. | `string` | `""` | no | | [ibmcloud\_api\_key](#input\_ibmcloud\_api\_key) | The IBM Cloud platform API key needed to deploy IAM enabled resources. | `string` | n/a | yes | | [powervs\_boot\_image\_storage\_tier](#input\_powervs\_boot\_image\_storage\_tier) | Storage type for server deployment. If storage type is not provided the storage type will default to tier3. Possible values tier0, tier1 and tier3 | `string` | `null` | no | | [powervs\_cpu\_proc\_type](#input\_powervs\_cpu\_proc\_type) | The type of processor mode in which the VM will run with shared, capped or dedicated. | `string` | n/a | yes | diff --git a/solutions/single-netweaver-instance/variables.tf b/solutions/single-netweaver-instance/variables.tf index eed49a34..899025a4 100644 --- a/solutions/single-netweaver-instance/variables.tf +++ b/solutions/single-netweaver-instance/variables.tf @@ -191,5 +191,5 @@ variable "ansible_vault_password" { description = "Vault password to encrypt ansible playbooks that contain sensitive information. Required with customer provided linux subscription (powervs_os_registration). Password requirements: 15-100 characters and at least one uppercase letter, one lowercase letter, one number, and one special character. Allowed characters: A-Z, a-z, 0-9, !#$%&()*+-.:;<=>?@[]_{|}~." type = string sensitive = true - default = null + default = "" } From 0ec22acc4220c66e33973968ea70d6d49ad7aae8 Mon Sep 17 00:00:00 2001 From: surajsbharadwaj Date: Tue, 14 Oct 2025 19:59:54 +0200 Subject: [PATCH 5/7] chore: upgrade landing zone SKIP UPGRADE TEST: landing zone sgs upgraded --- ibm_catalog.json | 8 ++++++ .../ibm-catalog/sap-ready-to-go/README.md | 3 ++- solutions/ibm-catalog/sap-ready-to-go/main.tf | 25 +++---------------- .../ibm-catalog/sap-ready-to-go/variables.tf | 20 +++++++++++++++ 4 files changed, 34 insertions(+), 22 deletions(-) diff --git a/ibm_catalog.json b/ibm_catalog.json index 04066d2c..07e2f993 100755 --- a/ibm_catalog.json +++ b/ibm_catalog.json @@ -404,6 +404,14 @@ } ], "custom_config": {} + }, + { + "key": "vpc_subnet_cidrs", + "custom_config": { + "grouping": "deployment", + "original_grouping": "deployment", + "type": "code_editor" + } } ], "iam_permissions": [ diff --git a/solutions/ibm-catalog/sap-ready-to-go/README.md b/solutions/ibm-catalog/sap-ready-to-go/README.md index 52155853..063099dc 100644 --- a/solutions/ibm-catalog/sap-ready-to-go/README.md +++ b/solutions/ibm-catalog/sap-ready-to-go/README.md @@ -73,7 +73,7 @@ | Name | Source | Version | |------|--------|---------| | [sap\_system](#module\_sap\_system) | ../../../modules/pi-sap-system-type1 | n/a | -| [standard](#module\_standard) | terraform-ibm-modules/powervs-infrastructure/ibm//modules/powervs-vpc-landing-zone | 10.0.1 | +| [standard](#module\_standard) | terraform-ibm-modules/powervs-infrastructure/ibm//modules/powervs-vpc-landing-zone | 10.1.1 | ### Resources @@ -121,6 +121,7 @@ | [ssh\_public\_key](#input\_ssh\_public\_key) | Public SSH Key for VSI creation. Must be an RSA key with a key size of either 2048 bits or 4096 bits (recommended). Must be a valid SSH key that does not already exist in the deployment region. | `string` | n/a | yes | | [tags](#input\_tags) | List of tag names for the IBM Cloud PowerVS workspace | `list(string)` | `[]` | no | | [vpc\_intel\_images](#input\_vpc\_intel\_images) | Stock OS image names for creating VPC landing zone VSI instances: RHEL (management and network services) and SLES (monitoring). |
object({
rhel_image = string
sles_image = string
})
|
{
"rhel_image": "ibm-redhat-9-6-amd64-sap-applications-1",
"sles_image": "ibm-sles-15-7-amd64-sap-applications-1"
}
| no | +| [vpc\_subnet\_cidrs](#input\_vpc\_subnet\_cidrs) | CIDR values for the VPC subnets to be created. It's customer responsibility that none of the defined networks collide, including the PowerVS subnets and VPN client pool. |
object({
vpn = string
mgmt = string
vpe = string
edge = string
})
|
{
"edge": "10.30.40.0/24",
"mgmt": "10.30.20.0/24",
"vpe": "10.30.30.0/24",
"vpn": "10.30.10.0/24"
}
| no | ### Outputs diff --git a/solutions/ibm-catalog/sap-ready-to-go/main.tf b/solutions/ibm-catalog/sap-ready-to-go/main.tf index a50b55d9..e482dabd 100644 --- a/solutions/ibm-catalog/sap-ready-to-go/main.tf +++ b/solutions/ibm-catalog/sap-ready-to-go/main.tf @@ -4,27 +4,9 @@ # PowerVS Workspace ####################################################### -locals { - powervs_management_network = { name = "${var.prefix}-sap-net", cidr = var.powervs_sap_network_cidr } - powervs_server_routes = concat( - [ - { - route_name = local.powervs_management_network.name - destination = local.powervs_management_network.cidr - action = "deliver" - } - ] - ) - - client_to_site_vpn = merge( - var.client_to_site_vpn, - { powervs_server_routes = local.powervs_server_routes } - ) -} - module "standard" { source = "terraform-ibm-modules/powervs-infrastructure/ibm//modules/powervs-vpc-landing-zone" - version = "10.0.1" + version = "10.1.1" providers = { ibm.ibm-is = ibm.ibm-is @@ -39,7 +21,7 @@ module "standard" { vpc_intel_images = var.vpc_intel_images ssh_public_key = var.ssh_public_key ssh_private_key = var.ssh_private_key - powervs_management_network = local.powervs_management_network + powervs_management_network = { name = "${var.prefix}-sap-net", cidr = var.powervs_sap_network_cidr } powervs_backup_network = null configure_dns_forwarder = true configure_ntp_forwarder = true @@ -50,7 +32,7 @@ module "standard" { powervs_custom_images = var.powervs_custom_images powervs_custom_image_cos_configuration = var.powervs_custom_image_cos_configuration powervs_custom_image_cos_service_credentials = var.powervs_custom_image_cos_service_credentials - client_to_site_vpn = local.client_to_site_vpn + client_to_site_vpn = var.client_to_site_vpn sm_service_plan = var.sm_service_plan existing_sm_instance_guid = var.existing_sm_instance_guid existing_sm_instance_region = var.existing_sm_instance_region @@ -58,6 +40,7 @@ module "standard" { existing_monitoring_instance_crn = var.existing_monitoring_instance_crn enable_scc_wp = var.enable_scc_wp ansible_vault_password = var.ansible_vault_password + vpc_subnet_cidrs = var.vpc_subnet_cidrs } diff --git a/solutions/ibm-catalog/sap-ready-to-go/variables.tf b/solutions/ibm-catalog/sap-ready-to-go/variables.tf index 8e83bf20..c91a1da2 100644 --- a/solutions/ibm-catalog/sap-ready-to-go/variables.tf +++ b/solutions/ibm-catalog/sap-ready-to-go/variables.tf @@ -361,3 +361,23 @@ variable "tags" { type = list(string) default = [] } + +##################################################### +# Optional Parameters VPC subnets +##################################################### + +variable "vpc_subnet_cidrs" { + description = "CIDR values for the VPC subnets to be created. It's customer responsibility that none of the defined networks collide, including the PowerVS subnets and VPN client pool." + type = object({ + vpn = string + mgmt = string + vpe = string + edge = string + }) + default = { + "vpn" = "10.30.10.0/24" + "mgmt" = "10.30.20.0/24" + "vpe" = "10.30.30.0/24" + "edge" = "10.30.40.0/24" + } +} From 67bd550f174137ab887a769eba58c0581c096fce Mon Sep 17 00:00:00 2001 From: Suraj Bharadwaj <101711050+surajsbharadwaj@users.noreply.github.com> Date: Wed, 15 Oct 2025 09:50:39 +0200 Subject: [PATCH 6/7] chore: update var description Co-authored-by: ludwig-mueller --- solutions/single-hana-instance/variables.tf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/solutions/single-hana-instance/variables.tf b/solutions/single-hana-instance/variables.tf index d52d5af2..0190f1b3 100644 --- a/solutions/single-hana-instance/variables.tf +++ b/solutions/single-hana-instance/variables.tf @@ -82,7 +82,7 @@ variable "powervs_networks" { } variable "powervs_hana_instance_custom_storage_config" { - description = "Custom file systems to be created and attached to PowerVS SAP HANA instance. 'size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the target mount point on OS." + description = "Custom file systems to be created and attached to PowerVS SAP HANA instance. 'size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the target mount point on OS. If not specified, volumes for '/hana/data', '/hana/log', '/hana/shared' are automatically calculated and created." type = list(object({ name = string size = string From c3bb58a0fb5a261b2c65259f668cd540940b5a8c Mon Sep 17 00:00:00 2001 From: surajsbharadwaj Date: Wed, 15 Oct 2025 09:55:26 +0200 Subject: [PATCH 7/7] chore: update var description SKIP UPGRADE TEST: breaking change new end to end solution --- modules/pi-sap-system-type1/README.md | 2 +- modules/pi-sap-system-type1/variables.tf | 2 +- solutions/ibm-catalog/sap-ready-to-go/README.md | 2 +- solutions/ibm-catalog/sap-ready-to-go/variables.tf | 2 +- solutions/single-hana-instance/README.md | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/modules/pi-sap-system-type1/README.md b/modules/pi-sap-system-type1/README.md index 43fb8549..2cdf24ab 100644 --- a/modules/pi-sap-system-type1/README.md +++ b/modules/pi-sap-system-type1/README.md @@ -49,7 +49,7 @@ The Power Virtual Server for SAP module automates the following tasks: |------|-------------|------|---------|:--------:| | [ansible\_vault\_password](#input\_ansible\_vault\_password) | Vault password to encrypt OS registration parameters. Only required with customer provided linux subscription (pi\_os\_registration). Password requirements: 15-100 characters and at least one uppercase letter, one lowercase letter, one number, and one special character. Allowed characters: A-Z, a-z, 0-9, !#$%&()*+-.:;<=>?@[]\_{\|}~. | `string` | `""` | no | | [pi\_hana\_instance](#input\_pi\_hana\_instance) | PowerVS SAP HANA instance hostname (non FQDN). Will get the form of -. Max length of final hostname must be <= 13 characters.'sap\_profile\_id' Must be one of the supported profiles. See [here](https://cloud.ibm.com/docs/sap?topic=sap-hana-iaas-offerings-profiles-power-vs). File system sizes are automatically calculated. Override automatic calculation by setting values in optional 'pi\_hana\_instance\_custom\_storage\_config' parameter. 'additional\_storage\_config' additional File systems to be created and attached to PowerVS SAP HANA instance. 'size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the target mount point on OS. |
object({
name = string
image_id = string
sap_profile_id = string
additional_storage_config = list(object({
name = string
size = string
count = string
tier = string
mount = string
}))
})
|
{
"additional_storage_config": [
{
"count": "1",
"mount": "/usr/sap",
"name": "usrsap",
"size": "50",
"tier": "tier3"
}
],
"image_id": "insert_value_here",
"name": "hana",
"sap_profile_id": "ush1-4x256"
}
| no | -| [pi\_hana\_instance\_custom\_storage\_config](#input\_pi\_hana\_instance\_custom\_storage\_config) | Custom file systems to be created and attached to PowerVS SAP HANA instance. 'size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the target mount point on OS. |
list(object({
name = string
size = string
count = string
tier = string
mount = string
}))
|
[
{
"count": "",
"mount": "",
"name": "",
"size": "",
"tier": ""
}
]
| no | +| [pi\_hana\_instance\_custom\_storage\_config](#input\_pi\_hana\_instance\_custom\_storage\_config) | Custom file systems to be created and attached to PowerVS SAP HANA instance. 'size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the target mount point on OS. If not specified, volumes for '/hana/data', '/hana/log', '/hana/shared' are automatically calculated and created. |
list(object({
name = string
size = string
count = string
tier = string
mount = string
}))
|
[
{
"count": "",
"mount": "",
"name": "",
"size": "",
"tier": ""
}
]
| no | | [pi\_instance\_init\_linux](#input\_pi\_instance\_init\_linux) | Configures a PowerVS linux instance to have internet access by setting proxy on it, updates os and create filesystems using ansible collection [ibm.power\_linux\_sap collection](https://galaxy.ansible.com/ui/repo/published/ibm/power_linux_sap/) where 'bastion\_host\_ip' is public IP of bastion/jump host to access the 'ansible\_host\_or\_ip' private IP of ansible node. This ansible host must have access to the power virtual server instance and ansible host OS must be RHEL distribution. |
object(
{
enable = bool
bastion_host_ip = string
ansible_host_or_ip = string
ssh_private_key = string
custom_os_registration = optional(object({
username = string
password = string
}))
}
)
| n/a | yes | | [pi\_netweaver\_instance](#input\_pi\_netweaver\_instance) | PowerVS SAP NetWeaver instance hostname (non FQDN). Will get the form of --. Max length of final hostname must be <= 13 characters. 'instance\_count' is number of SAP NetWeaver instances that should be created. 'instance\_count' cannot exceed 10. 'size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the target mount point on OS. |
object({
instance_count = number
name = string
image_id = string
processors = string
memory = string
proc_type = string
storage_config = list(object({
name = string
size = string
count = string
tier = string
mount = string
}))
})
|
{
"image_id": "insert_value_here",
"instance_count": 1,
"memory": "32",
"name": "nw",
"proc_type": "shared",
"processors": "3",
"storage_config": [
{
"count": "1",
"mount": "/usr/sap",
"name": "usrsap",
"size": "50",
"tier": "tier3"
}
]
}
| no | | [pi\_networks](#input\_pi\_networks) | Existing list of subnets to be attached to PowerVS instances. The first element will become the primary interface. Run 'ibmcloud pi networks' to list available private subnets. |
list(
object({
name = string
id = string
cidr = optional(string)
})
)
| n/a | yes | diff --git a/modules/pi-sap-system-type1/variables.tf b/modules/pi-sap-system-type1/variables.tf index 07264d3f..97b02cd0 100644 --- a/modules/pi-sap-system-type1/variables.tf +++ b/modules/pi-sap-system-type1/variables.tf @@ -75,7 +75,7 @@ variable "pi_hana_instance" { } variable "pi_hana_instance_custom_storage_config" { - description = "Custom file systems to be created and attached to PowerVS SAP HANA instance. 'size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the target mount point on OS." + description = "Custom file systems to be created and attached to PowerVS SAP HANA instance. 'size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the target mount point on OS. If not specified, volumes for '/hana/data', '/hana/log', '/hana/shared' are automatically calculated and created." type = list(object({ name = string size = string diff --git a/solutions/ibm-catalog/sap-ready-to-go/README.md b/solutions/ibm-catalog/sap-ready-to-go/README.md index 063099dc..a517caa2 100644 --- a/solutions/ibm-catalog/sap-ready-to-go/README.md +++ b/solutions/ibm-catalog/sap-ready-to-go/README.md @@ -103,7 +103,7 @@ | [powervs\_custom\_images](#input\_powervs\_custom\_images) | Optionally import up to three custom images from Cloud Object Storage into PowerVS workspace. Requires 'powervs\_custom\_image\_cos\_configuration' to be set. image\_name: string, must be unique. Name of image inside PowerVS workspace. file\_name: string, object key of image inside COS bucket. storage\_tier: string, storage tier which image will be stored in after import. Supported values: tier0, tier1, tier3, tier5k. sap\_type: optional string, Supported values: null, Hana, Netweaver, use null for non-SAP image. |
object({
powervs_custom_image1 = object({
image_name = string
file_name = string
storage_tier = string
sap_type = optional(string)
}),
powervs_custom_image2 = object({
image_name = string
file_name = string
storage_tier = string
sap_type = optional(string)
}),
powervs_custom_image3 = object({
image_name = string
file_name = string
storage_tier = string
sap_type = optional(string)
})
})
|
{
"powervs_custom_image1": {
"file_name": "",
"image_name": "",
"sap_type": null,
"storage_tier": ""
},
"powervs_custom_image2": {
"file_name": "",
"image_name": "",
"sap_type": null,
"storage_tier": ""
},
"powervs_custom_image3": {
"file_name": "",
"image_name": "",
"sap_type": null,
"storage_tier": ""
}
}
| no | | [powervs\_default\_sap\_images](#input\_powervs\_default\_sap\_images) | Default SUSE and Red Hat Linux Full Linux subscription images to use for PowerVS SAP HANA and SAP NetWeaver instances. If you're using a byol or a custom RHEL/SLES image, additionally specify the optional values for 'powervs\_os\_registration\_username', 'powervs\_os\_registration\_password' and 'ansible\_vault\_password' |
object({
sles_hana_image = string
sles_nw_image = string
rhel_hana_image = string
rhel_nw_image = string
})
|
{
"rhel_hana_image": "RHEL9-SP4-SAP",
"rhel_nw_image": "RHEL9-SP4-SAP-NETWEAVER",
"sles_hana_image": "SLES15-SP6-SAP",
"sles_nw_image": "SLES15-SP6-SAP-NETWEAVER"
}
| no | | [powervs\_hana\_instance\_additional\_storage\_config](#input\_powervs\_hana\_instance\_additional\_storage\_config) | Additional File systems to be created and attached to PowerVS SAP HANA instance. 'size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the target mount point on OS. |
list(object({
name = string
size = string
count = string
tier = string
mount = string
}))
|
[
{
"count": "1",
"mount": "/usr/sap",
"name": "usrsap",
"size": "50",
"tier": "tier3"
}
]
| no | -| [powervs\_hana\_instance\_custom\_storage\_config](#input\_powervs\_hana\_instance\_custom\_storage\_config) | Custom file systems to be created and attached to PowerVS SAP HANA instance. 'size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the target mount point on OS. |
list(object({
name = string
size = string
count = string
tier = string
mount = string
pool = optional(string)
}))
|
[
{
"count": "",
"mount": "",
"name": "",
"size": "",
"tier": ""
}
]
| no | +| [powervs\_hana\_instance\_custom\_storage\_config](#input\_powervs\_hana\_instance\_custom\_storage\_config) | Custom file systems to be created and attached to PowerVS SAP HANA instance. 'size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the target mount point on OS. If not specified, volumes for '/hana/data', '/hana/log', '/hana/shared' are automatically calculated and created. |
list(object({
name = string
size = string
count = string
tier = string
mount = string
pool = optional(string)
}))
|
[
{
"count": "",
"mount": "",
"name": "",
"size": "",
"tier": ""
}
]
| no | | [powervs\_hana\_instance\_sap\_profile\_id](#input\_powervs\_hana\_instance\_sap\_profile\_id) | PowerVS SAP HANA instance profile to use. Must be one of the supported profiles. See [here](https://cloud.ibm.com/docs/sap?topic=sap-hana-iaas-offerings-profiles-power-vs). File system sizes are automatically calculated. Override automatic calculation by setting values in optional parameter 'powervs\_hana\_instance\_custom\_storage\_config'. | `string` | `"sh2-4x256"` | no | | [powervs\_netweaver\_cpu\_number](#input\_powervs\_netweaver\_cpu\_number) | Number of CPUs for each PowerVS SAP NetWeaver instance. | `string` | `"3"` | no | | [powervs\_netweaver\_instance\_count](#input\_powervs\_netweaver\_instance\_count) | Number of PowerVS SAP NetWeaver instances that should be created. 'powervs\_netweaver\_instance\_count' cannot exceed 10. | `number` | `1` | no | diff --git a/solutions/ibm-catalog/sap-ready-to-go/variables.tf b/solutions/ibm-catalog/sap-ready-to-go/variables.tf index c91a1da2..2e8e558f 100644 --- a/solutions/ibm-catalog/sap-ready-to-go/variables.tf +++ b/solutions/ibm-catalog/sap-ready-to-go/variables.tf @@ -61,7 +61,7 @@ variable "powervs_hana_instance_sap_profile_id" { } variable "powervs_hana_instance_custom_storage_config" { - description = "Custom file systems to be created and attached to PowerVS SAP HANA instance. 'size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the target mount point on OS." + description = "Custom file systems to be created and attached to PowerVS SAP HANA instance. 'size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the target mount point on OS. If not specified, volumes for '/hana/data', '/hana/log', '/hana/shared' are automatically calculated and created." type = list(object({ name = string size = string diff --git a/solutions/single-hana-instance/README.md b/solutions/single-hana-instance/README.md index a464025e..d0abe119 100644 --- a/solutions/single-hana-instance/README.md +++ b/solutions/single-hana-instance/README.md @@ -44,7 +44,7 @@ No resources. | [powervs\_boot\_image\_storage\_tier](#input\_powervs\_boot\_image\_storage\_tier) | Storage type for server deployment. If storage type is not provided the storage type will default to tier3. Possible values tier0, tier1 and tier3 | `string` | `null` | no | | [powervs\_deployment\_target](#input\_powervs\_deployment\_target) | The deployment of a dedicated host. Max items: 1, id is the uuid of the host group or host. type is the deployment target type, supported values are host and hostGroup |
list(object(
{
type = string
id = string
}
))
| `null` | no | | [powervs\_hana\_instance\_additional\_storage\_config](#input\_powervs\_hana\_instance\_additional\_storage\_config) | Additional File systems to be created and attached to PowerVS SAP HANA instance. 'size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the target mount point on OS. |
list(object({
name = string
size = string
count = string
tier = string
mount = string
}))
|
[
{
"count": "1",
"mount": "/usr/sap",
"name": "usrsap",
"size": "50",
"tier": "tier3"
}
]
| no | -| [powervs\_hana\_instance\_custom\_storage\_config](#input\_powervs\_hana\_instance\_custom\_storage\_config) | Custom file systems to be created and attached to PowerVS SAP HANA instance. 'size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the target mount point on OS. |
list(object({
name = string
size = string
count = string
tier = string
mount = string
pool = optional(string)
}))
|
[
{
"count": "",
"mount": "",
"name": "",
"size": "",
"tier": ""
}
]
| no | +| [powervs\_hana\_instance\_custom\_storage\_config](#input\_powervs\_hana\_instance\_custom\_storage\_config) | Custom file systems to be created and attached to PowerVS SAP HANA instance. 'size' is in GB. 'count' specify over how many storage volumes the file system will be striped. 'tier' specifies the storage tier in PowerVS workspace. 'mount' specifies the target mount point on OS. If not specified, volumes for '/hana/data', '/hana/log', '/hana/shared' are automatically calculated and created. |
list(object({
name = string
size = string
count = string
tier = string
mount = string
pool = optional(string)
}))
|
[
{
"count": "",
"mount": "",
"name": "",
"size": "",
"tier": ""
}
]
| no | | [powervs\_hana\_instance\_sap\_profile\_id](#input\_powervs\_hana\_instance\_sap\_profile\_id) | PowerVS SAP HANA instance profile to use. Must be one of the supported profiles. See [here](https://cloud.ibm.com/docs/sap?topic=sap-hana-iaas-offerings-profiles-power-vs). File system sizes are automatically calculated. Override automatic calculation by setting values in optional parameter 'powervs\_hana\_instance\_custom\_storage\_config'. | `string` | `"sh2-4x256"` | no | | [powervs\_image\_name](#input\_powervs\_image\_name) | Image name used for PowerVS instance. Run 'ibmcloud pi images' to list available images. | `string` | n/a | yes | | [powervs\_instance\_init\_linux](#input\_powervs\_instance\_init\_linux) | Configures a PowerVS linux instance to have internet access by setting proxy on it, updates os and create filesystems using ansible collection [ibm.power\_linux\_sap collection](https://galaxy.ansible.com/ui/repo/published/ibm/power_linux_sap/). where 'proxy\_host\_or\_ip\_port' E.g., 10.10.10.4:3128 , 'bastion\_host\_ip' is public IP of bastion/jump host to access the private IP of created linux PowerVS instance. |
object(
{
enable = bool
bastion_host_ip = string
ansible_host_or_ip = string
}
)
|
{
"ansible_host_or_ip": "",
"bastion_host_ip": "",
"enable": false
}
| no |