0
respostas

[Bug] Erro ao Criar Cluster ECS

Fiz a alteração para adequar a nova versão do module ECS.

Porém estou tendo o erro abaixo:

Error: error updating ECS Cluster (staging) Capacity Providers: InvalidParameterException: The specified capacity provider was not found. Specify a valid capacit y provider and try again. │ │ with module.ecs.aws_ecs_cluster_capacity_providers.this[0], │ on .terraform\modules\ecs\main.tf line 60, in resource "aws_ecs_cluster_capacity_providers" "this": │ 60: resource "aws_ecs_cluster_capacity_providers" "this" {

Segue codigo do ECS


#Configura o ECS
module "ecs" {
  source                              = "terraform-aws-modules/ecs/aws"
  cluster_name                        = var.ambiente

  # Capacity provider
  fargate_capacity_providers = {
    FARGATE = {
      default_capacity_provider_strategy = {
        weight = 50
        base   = 20
      }
    }
    FARGATE_SPOT = {
      default_capacity_provider_strategy = {
        weight = 50
      }
    }
    cluster_settings = {
      "name" : "containerInsights",
      "value" : "enabled"
    }
  }
}