Skip to content

Commit

Permalink
Add depreciated field for backward compatibility (#410)
Browse files Browse the repository at this point in the history
  • Loading branch information
sarvesh-cast authored Oct 24, 2024
1 parent bf0a3b0 commit c4d6ee8
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 11 deletions.
2 changes: 1 addition & 1 deletion examples/eks/eks_cluster_gitops/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ echo "Authentication mode is $current_auth_mode"
apiVersion: v1
data:
mapRoles: |
- rolearn: arn:aws:iam::028075177508:role/castai-eks-<clustername>
- rolearn: arn:aws:iam::028075177508:role/castai-eks-instance-<clustername>
username: system:node:{{EC2PrivateDNSName}}
groups:
- system:bootstrappers
Expand Down
16 changes: 8 additions & 8 deletions examples/gke/gke_cluster_existing/castai.tf
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,11 @@ module "castai-gke-cluster" {
}
node_templates = {
default_by_castai = {
name = "default-by-castai"
configuration_id = module.castai-gke-cluster.castai_node_configurations["default"]
is_default = true
is_enabled = true
should_taint = false
custom_instances_enabled = true
name = "default-by-castai"
configuration_id = module.castai-gke-cluster.castai_node_configurations["default"]
is_default = true
is_enabled = true
should_taint = false

constraints = {
on_demand = true
Expand All @@ -62,7 +61,7 @@ module "castai-gke-cluster" {
configuration_id = module.castai-gke-cluster.castai_node_configurations["default"]
is_enabled = true
should_taint = true
custom_instances_enabled = true
custom_instances_enabled = false # custom_instances_enabled should be set to same value(true or false) at Node templates & unschedulable_pods policy for backward compatability

custom_labels = {
custom-label-key-1 = "custom-label-value-1"
Expand Down Expand Up @@ -103,7 +102,8 @@ module "castai-gke-cluster" {
node_templates_partial_matching_enabled = false

unschedulable_pods = {
enabled = false
enabled = false
custom_instances_enabled = false # custom_instances_enabled should be set to same value(true or false) at Node templates & unschedulable_pods policy for backward compatability
}

node_downscaler = {
Expand Down
5 changes: 3 additions & 2 deletions examples/gke/gke_cluster_gitops/castai.tf
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ resource "castai_node_template" "example_spot_template" {
is_enabled = true
configuration_id = castai_node_configuration.default.id
should_taint = true
custom_instances_enabled = true # gke specific
custom_instances_enabled = false # custom_instances_enabled should be set to same value(true or false) at Node templates & unschedulable_pods policy for backward compatability

custom_labels = {
type = "spot"
Expand Down Expand Up @@ -95,7 +95,8 @@ resource "castai_autoscaler" "castai_autoscaler_policy" {
node_templates_partial_matching_enabled = false

unschedulable_pods {
enabled = true
enabled = true
custom_instances_enabled = false # custom_instances_enabled should be set to same value(true or false) at Node templates & unschedulable_pods policy for backward compatability
}

cluster_limits {
Expand Down

0 comments on commit c4d6ee8

Please sign in to comment.