Skip to content

Commit

Permalink
fix: fixes condition when bastion/operator are set to false and no (#585
Browse files Browse the repository at this point in the history
)

ip addresses are provided

Resolves #584

Signed-off-by: Ali Mukadam <[email protected]>

Signed-off-by: Ali Mukadam <[email protected]>
  • Loading branch information
hyder authored Oct 6, 2022
1 parent 269d3fd commit 6b84a48
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions locals.tf
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ locals {
var.tenancy_id, var.tenancy_ocid,
)

bastion_public_ip = var.create_bastion_host == true ? module.bastion[0].bastion_public_ip : coalesce(var.bastion_public_ip, "")
operator_private_ip = var.create_operator == true ? module.operator[0].operator_private_ip : coalesce(var.operator_private_ip, "")
bastion_public_ip = var.create_bastion_host == true ? module.bastion[0].bastion_public_ip : var.bastion_public_ip != "" ? var.bastion_public_ip: ""
operator_private_ip = var.create_operator == true ? module.operator[0].operator_private_ip : var.operator_private_ip !="" ? var.operator_private_ip: ""
operator_instance_principal_group_name = var.create_operator == true ? module.operator[0].operator_instance_principal_group_name : ""

vcn_id = var.create_vcn == true ? module.vcn[0].vcn_id : coalesce(var.vcn_id, try(data.oci_core_vcns.vcns[0].virtual_networks[0].id,""))
Expand Down

0 comments on commit 6b84a48

Please sign in to comment.