Variables in Terraform Scripts

The variables you need input to the terraform scripts in Oracle WebLogic Server for OKE.

Note:

If you are using Oracle WebLogic Server for OKE (Release 21.3.3 or later), see Terraform Scripts in Oracle WebLogic Server for OKE.

The following table lists all the variables in terraform scripts:

Table 1-1 Variables in terraform scripts

Variables Type Default Value Optional Can be updated? Description

Authentication Information

Note: Use env_vars_template to create env_vars and source it as: source ./env_vars before running terraform init.

- - - - -

FingerPrint

String - - Yes Fingerprint of the OCI API private key.

Path to private key

String - - - Path to the private key that matches the fingerprint.

Tenancy OCID

String - - - OCID of the tenancy in which you want to perform changes.

User OCID

String - - - OCID of the signed in user. That is, your OCID.

WebLogic Server Variables

- - - - -

compartment_ocid

String - - - OCID of the compartment for WebLogic instances.

region

String - - - Region for provisioning.

service_name

String - - - Prefix for stack resources. The names of all the related compute and network resources begins with the prefix you assign here.

ssh_public_key

String - - - Content of public key for access.

wls_admin_password_ocid

String - - - OCID of the Secret that contains the password for the administrator in the WebLogic Server domain.

wls_admin_user

String weblogic Yes - Name of the administrator in the WebLogic Server domain.

General

- - - - -

create_policies

Boolean true Yes - Create policies to read Secrets from Vault and manage ATP database (if applicable).

Container Cluster (OKE) Configuration

- - - - -

existing_cluster_id

String - - - Existing cluster ID value.

kubernetes_version

String Latest Kubernetes version is displayed by default. Yes - Kubernetes version.

non_wls_node_pool_count

String 1 - Yes

Count of the non-WLS node pool.

Note: If you update the node pool count, then the node pool is recreated. If you scale the compute instance and the WebLogic server Operator does not connect to the WebLogic server Persistence store, see Scaling Compute Instances.

non_wls_node_pool_shape

String VM.Standard2.1 - Yes Shape of the non-WLS node pool.

pods_cidr

String - Yes - CIDR value of the OKE pod.

services_cidr

String - Yes - CIDR value of the services.

wls_node_pool_count

String 1 - Yes Count of the WLS node pool.

wls_node_pool_shape

String VM.Standard2.1 - Yes Shape of the WLS node pool.

Container Cluster (OKE) Administration Instances

- - - - -

admin_availability_domain

String - - - Name of the availability domain for the administrator instance.

admin_shape

String VM.Standard.E2.1 - - Shape for administrator instance.

bastion_shape

String VM.Standard.E2.1 - - Shape for bastion instance.

Network Variables

- - - - -

existing_vcn_id

String - - - OCID of an existing VCN where you want to create the compute instances, network resources, and load balancers.

existing_lb_subnet_id

String - - - OCID of an existing load balancer subnets.

existing_bastion_subnet_id

String - - - OCID for an existing bastion subnet.

existing_oke_workers_subnet_id

String - - - OCID for an OKE worker node subnet.

existing_admin_subnet_id

String - - - OCID for an existing administrator subnet.

existing_fss_subnet_id

String - - - OCID for an existing FSS subnet.

existing_nat_gw_id

String - Yes -

OCID for an existing NAT gateway.

Note: You need to specify either the NAT gateway (existing_nat_gw_id) or service gateway (existing_service_gw_id).

existing_service_gw_id

String - Yes -

OCID for an existing service gateway.

Note: You need to specify either the NAT gateway (existing_nat_gw_id) or service gateway (existing_service_gw_id).

is_bastion_instance_required

Boolean true Yes - Creates bastion for the stack.

If true, it provisions a bastion compute instance on a public subnet to provide access to the WebLogic server compute instances on a private subnet.

Load Balancer Variables

- - - - -

lb_shape

String flexible - - Shape of the public load balancer.

ingress_lb_shape

String flexible - - Shape of the ingress load balancer.

Shared File System Variables

- - - - -

fss_availability_domain

String - - - OCID of the availability domain for Shared File System.

mountTarget_id

String - Yes - OCID for the mount target.

mountTarget_compartment_id

String - Yes - OCID of the compartment for the mount target.

This variable is required if mountTarget_id is updated.

OCIR Variables

  - -    

ocir_user

String - - - OCIR user name.

ocir_auth_token_ocid

String - - - OCID token for the OCIR user name.

IDCS-related Variables

- - - - -

idcs_client_id

String - - - IDCS client ID value.

idcs_client_secret_ocid

String - - - IDCS client secret OCID value.

idcs_cloudgate_port

Number 9999 Yes - IDCS cloud gate port value.

idcs_host

String identity.oraclecloud.com Yes - IDCS host value.

idcs_port

Number 443 Yes - IDCS port value.

idcs_tenant

String - - - IDCS tenant value.

is_idcs_selected

Boolean false Yes - If you want an IDCS has to be provisioned.

OCI Database Variables

- - - - -

ocidb_compartment_id

String - - -

OCID of the OCI database compartment.

ocidb_dbsystem_id

String - - -

OCID of the OCI database system.

ocidb_database_id

String - - -

OCID of the OCI database.

ocidb_pdb_service_name

String - - - PDB name of the OCI database.

oci_db_user

String sys Yes - OCI database username

oci_db_password

String - - - OCID of the OCI database password.

ATP Database Variables

  - -    

atp_db_compartment_id

String - - - OCID of the ATP database compartment.

atp_db_id

String - - - OCID of the ATP database.

atp_db_level

String - - - ATP database level value.

atp_db_password_ocid

String - - - OCID of the ATP database password.

Note:

Support for existing bastion host to be used in provisioning WebLogic server with private subnet is enabled in terraform CLI only. This can be achieved by using the varaibles: is_bastion_instance_required, existing_bastion_instance_id, and bastion_ssh_private_key. For existing WebLogic server subnet, you will need to open port 22 for bastion IP/subnet CIDR. For a new WebLogic server subnet we create security list with bastion private IP.