Redundant ignore_changes element: in resource "aws_lambda_function" "this"
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 1/5
- Tempo estimado
- Menos de uma hora
- Facilidade para iniciantes
- 55/100
- Tipo de issue
- Bug
- Clareza
- Claramente especificada
- Status de atividade
- Estagnada
- Stack de tecnologia
- aws, terraform
- Domínio
- cloud, infrastructure
Direção de pesquisa
Comece em main.tf, próximo ao bloco lifecycle nas linhas 93–95, e analise o aviso do Terraform para o recurso aws_lambda_function. Reproduza o problema com o Terraform v1.5.6, o AWS provider v5.19.0 e a configuração do módulo s3_bucket/s3_key descrita no relatório. O trabalho estará concluído quando terraform plan ou apply for concluído sem o aviso redundante de ignore_changes.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
Describe the Bug
When running terraform plan (or apply), a declaration of this module throws the following warning:
│ Warning: Redundant ignore_changes element
│
│ on .terraform/modules/foo.lambda_changes/main.tf line 21, in resource "aws_lambda_function" "this":
│ 21: resource "aws_lambda_function" "this" {
│
│ Adding an attribute name to ignore_changes tells Terraform to ignore future changes to the argument in configuration after the object has been created, retaining the value originally configured.
│
│ The attribute last_modified is decided by the provider alone and therefore there can be no configured value to compare with. Including this attribute in ignore_changes has no effect. Remove the attribute from ignore_changes to quiet this
│ warning.
│
│ (and one more similar warning elsewhere)
The error is coming from the lifecycle block at https://github.com/cloudposse/terraform-aws-lambda-function/blob/0.5.1/main.tf#L93-L95
lifecycle {
ignore_changes = [last_modified]
}
Expected Behavior
When running terraform plan (or apply), a declaration of this module does not throw a "Redundant ignore_changes element" warning
Steps to Reproduce
In my case, I declared this module with s3_bucket and s3_key:
module "lambda_responses" {
source = "cloudposse/lambda-function/aws"
version = "0.5.1"
function_name = "${module.lambda_label.id}-test"
attributes = concat(module.lambda_label.attributes, ["test"])
description = "Yay lambdas"
s3_bucket = var.responses_lambda_s3_bucket
s3_key = var.responses_lambda_s3_key
runtime = var.responses_lambda_runtime
handler = var.responses_lambda_handler
architectures = ["x86_64"]
context = module.lambda_label.context
}
Then ran terraform apply from the root module shown above.
The Lambda and related resources were created just fine, but the Terraform run ended with the "ignore_changes" warning.
Environment
Versions:
- Terraform v1.5.6
- module cloudposse/lambda-function/aws 0.5.1
- provider registry.terraform.io/hashicorp/aws v5.19.0
- provider registry.terraform.io/hashicorp/time v0.9.1
Additional Context
Root cause and the reason for the lifecycle block in the first place: https://github.com/hashicorp/terraform-provider-aws/issues/29085
- Linguagem predominante
- HCL
- Estrelas
- 36
- Forks
- 44
- Métricas de merge de PRs
- Nenhum PR com merge em 30d
Preparar o ambiente
- Sem Dockerfile nem arquivo Docker Compose
- Tem um modelo de pull request
- Ler o guia de contribuição
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de cloudposse/terraform-aws-lambda-function
-
bug
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 58/100
-
Warning: Deprecated attributeTalvez já em andamento @arnoldasbrazys assumiu há 402 dias. Abertabug
Dificuldade 1/5 Menos de uma hora Facilidade para iniciantes 55/100
cloudposse/terraform-aws-lambda-function#89 · 1 reação ·
-
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 45/100
cloudposse/terraform-aws-lambda-function#84 · 3 reações ·
-
bug
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 35/100
cloudposse/terraform-aws-lambda-function#72 · 1 comentário · 2 reações ·
-
bug
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 35/100
cloudposse/terraform-aws-lambda-function#62 · 1 comentário ·
Todas as issues de cloudposse/terraform-aws-lambda-function
Issues semelhantes
-
No native support for REDIS_USER enviroment varTalvez já em andamento @jholmes802 assumiu hoje. Aberta
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 70/100
-
azurerm_backup_policy_file_share hourly backup interval does not support all available valuesAbertaenhancement service/recovery-services v/5.x
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 68/100
hashicorp/terraform-provider-azurerm#33587 ·
Mantenedores costumam responder em até 1 dia
-
[BUG] ovh_domain_zone_dnssec Read discards the API response, so status drift is never detectedAberta
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
ovh/terraform-provider-ovh#1473 ·
Mantenedores costumam responder em até 1 dia
-
Bump up AWS SDK to 2.54.3Aberta
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 68/100
jenkinsci/ec2-plugin#2041 ·