Skip to content

Commit bd12a1d

Browse files
committed
module updates
Signed-off-by: junior <junior@users.noreply.github.com>
1 parent 4cc765e commit bd12a1d

File tree

2 files changed

+10
-4
lines changed

2 files changed

+10
-4
lines changed

module-cluster-tools.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ module "cluster-tools" {
2929
## Grafana
3030
grafana_enabled = var.grafana_enabled
3131

32-
depends_on = [module.oke]
32+
depends_on = [module.oke, module.oke_node_pool, module.oke_cluster_autoscaler]
3333
}
3434

3535
# Kubernetes Cluster Tools

module-oke.tf

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,7 @@ module "oke_node_pool" {
9292
node_pool_shape = each.value.node_pool_shape
9393
node_pool_node_shape_config_ocpus = each.value.node_pool_node_shape_config_ocpus
9494
node_pool_node_shape_config_memory_in_gbs = each.value.node_pool_node_shape_config_memory_in_gbs
95+
existent_oke_nodepool_id_for_autoscaler = each.value.existent_oke_nodepool_id_for_autoscaler
9596
public_ssh_key = local.workers_public_ssh_key
9697

9798
# OKE Network Details
@@ -111,6 +112,7 @@ locals {
111112
node_pool_node_shape_config_ocpus = var.node_pool_instance_shape.ocpus
112113
node_pool_node_shape_config_memory_in_gbs = var.node_pool_instance_shape.memory
113114
node_pool_boot_volume_size_in_gbs = var.node_pool_boot_volume_size_in_gbs
115+
existent_oke_nodepool_id_for_autoscaler = var.existent_oke_nodepool_id_for_autoscaler_1
114116
},
115117
]
116118
}
@@ -201,11 +203,15 @@ variable "cluster_autoscaler_enabled" {
201203
}
202204
variable "cluster_autoscaler_min_nodes_1" {
203205
default = 3
204-
description = "Minimum number of nodes on the node pool to be scheduled by the Kubernetes"
206+
description = "Minimum number of nodes on the node pool to be scheduled by the Kubernetes (pool1)"
205207
}
206208
variable "cluster_autoscaler_max_nodes_1" {
207209
default = 10
208-
description = "Maximum number of nodes on the node pool to be scheduled by the Kubernetes"
210+
description = "Maximum number of nodes on the node pool to be scheduled by the Kubernetes (pool1)"
211+
}
212+
variable "existent_oke_nodepool_id_for_autoscaler_1" {
213+
default = ""
214+
description = "Nodepool Id of the existent OKE to use with Cluster Autoscaler (pool1)"
209215
}
210216

211217
## OKE Node Pool Details
@@ -269,7 +275,7 @@ variable "create_compartment_policies" {
269275
variable "tag_values" {
270276
type = map(any)
271277
default = { "freeformTags" = {
272-
"Environment" = "Development", # e.g.: Demo, Sandbox, Development, QA, Stage, ...
278+
"Environment" = "Development", # e.g.: Demo, Sandbox, Development, QA, Stage, ...
273279
"DeploymentType" = "generic" } } # e.g.: App Type 1, App Type 2, Red, Purple, ...
274280
description = "Use Tagging to add metadata to resources. All resources created by this stack will be tagged with the selected tag values."
275281
}

0 commit comments

Comments
 (0)