Skip to content

Commit

Permalink
Merge pull request #6 from castai/fix/allow-to-change-evictor
Browse files Browse the repository at this point in the history
fix: allow cluster-controller to install evictor
  • Loading branch information
aldor007 authored May 5, 2022
2 parents e57dd47 + 2312f14 commit 460101d
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ resource "helm_release" "castai_agent" {
namespace = "castai-agent"
create_namespace = true
cleanup_on_fail = true
wait = true

set {
name = "provider"
Expand Down Expand Up @@ -46,13 +47,18 @@ resource "helm_release" "castai_evictor" {
namespace = "castai-agent"
create_namespace = true
cleanup_on_fail = true
wait = true

set {
name = "replicaCount"
value = "0"
}

depends_on = [helm_release.castai_agent]

lifecycle {
ignore_changes = [set, version]
}
}

resource "helm_release" "castai_cluster_controller" {
Expand All @@ -62,6 +68,7 @@ resource "helm_release" "castai_cluster_controller" {
namespace = "castai-agent"
create_namespace = true
cleanup_on_fail = true
wait = true

set {
name = "castai.clusterID"
Expand All @@ -88,5 +95,5 @@ resource "castai_autoscaler" "castai_autoscaler_policies" {
autoscaler_policies_json = var.autoscaler_policies_json
cluster_id = castai_gke_cluster.castai_cluster.id

depends_on = [helm_release.castai_agent]
depends_on = [helm_release.castai_agent, helm_release.castai_evictor]
}

0 comments on commit 460101d

Please sign in to comment.