Skip to content

Conversation

JaderDias
Copy link

Related Issues

  • [none]

Public Changelog

[none]

Security Implications

[none]

In recent versions of Terraform the former was deprecated in favor
of the latter.

Since then the following warnings are issued

 Warning: Argument is deprecated
│
│   with module.lambda-at-edge.aws_s3_bucket_object.artifact,
│   on .terraform/modules/lambda-at-edge/main.tf line 44, in resource "aws_s3_bucket_object" "artifact":
│   44:   bucket = var.s3_artifact_bucket
│
│ Use the aws_s3_object resource instead
│
│ (and 5 more similar warnings elsewhere)

This commit prevents such warnings
In recent versions of Terraform the attribute last_modified
was made redundant, and issues the following warning:

 Warning: Redundant ignore_changes element
│
│   on ../../terraform-aws-lambda-at-edge/main.tf line 54, in resource "aws_lambda_function" "lambda":
│   54: resource "aws_lambda_function" "lambda" {
│
│ 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.

This commit prevents this warning.
with this version the user can choose to omit the s3_artifact_bucket
variable, allowing the direct upload of the code to AWS Lambda
without first uploading it to S3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant