Skip to content

Commit

Permalink
add variable to use internal ip endpoints when running kubectl commands
Browse files Browse the repository at this point in the history
  • Loading branch information
f4tal-err0r authored and Yared Mekuria committed Apr 12, 2022
1 parent 40ef1a1 commit c1d30ef
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions modules/asm/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ module "cpr" {
project_id = var.project_id
cluster_name = var.cluster_name
cluster_location = var.cluster_location
internal_ip = var.kubectl_internal_ip

kubectl_create_command = "${path.module}/scripts/create_cpr.sh ${local.revision_name} ${local.channel} ${var.enable_cni} ${var.enable_vpc_sc}"
kubectl_destroy_command = "${path.module}/scripts/destroy_cpr.sh ${local.revision_name}"
Expand Down
6 changes: 6 additions & 0 deletions modules/asm/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -86,3 +86,9 @@ variable "enable_mesh_feature" {
type = bool
default = false
}

variable "kubectl_internal_ip" {
description = "Use internal ip for the cluster endpoint when running kubectl commands."
type = bool
default = false
}

0 comments on commit c1d30ef

Please sign in to comment.