module "cluster-autoscaler" {
  source = "../../../modules/app"

  kubeconfig_path = module.kubeconfig.path
  workflow        = "deploy-new-region-cluster-autoscaler.yaml"
  parameters = {
    env               = var.env
    region            = var.aws_region
    cluster           = module.argocd_cluster.name
    logicalRegionName = var.logical_region_name
    role-arn          = module.iam-cluster-autoscaler.role_arn
  }
  services = [
    {
      name      = "deploy/cluster-autoscaler"
      namespace = "kube-system"
      wait_for  = "jsonpath='{.status.availableReplicas}'=REPLICAS"
    }
  ]
}