resource "aws_s3_bucket_object" "distribution_zip" {
bucket = "veriluma-lambda-functions"
key = "mna-create-assessment.zip"
source = "${var.distribution_zip}"
etag = "${md5(file(var.distribution_zip))}"
}variable "distribution_zip" {}
${md5(file("${var.distribution_zip}")))--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
GitHub Issues: https://github.com/hashicorp/terraform/issues
IRC: #terraform-tool on Freenode
---
You received this message because you are subscribed to a topic in the Google Groups "Terraform" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/terraform-tool/B5j2XswL9_M/unsubscribe.
To unsubscribe from this group and all its topics, send an email to terraform-too...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/terraform-tool/2d0ed5c2-ca88-4a1e-b0ca-e92a9484ed9b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
"${md5(file("${var.distribution_zip}")))" ## Note 3 parentheses, not 2 and a }
"${md5(file("${var.distribution_zip}"))}"
[jyoung@hostname testing]$ cat s3.tf resource "aws_s3_bucket_object" "distribution_zip" { bucket = "veriluma-lambda-functions" key = "mna-create-assessment.zip" source = "${var.distribution_zip}" etag = "${md5(file("${var.distribution_zip}"))}"}
[jyoung@hostname testing]$ cat vars.tf variable "distribution_zip" {}
[jyoung@hostname testing]$ terraform -versionTerraform v0.7.1
[jyoung@hostname testing]$ AWS_PROFILE=account.profile terraform plan -var distribution_zip=testing.zipprovider.aws.region The region where AWS operations will take place. Examples are us-east-1, us-west-2, etc.
Default: us-east-1 Enter a value: [PRESSED ENTER TO ACCEPT DEFAULT]
Refreshing Terraform state in-memory prior to plan...The refreshed state will be used to calculate this plan, butwill not be persisted to local or remote state storage.
The Terraform execution plan has been generated and is shown below.Resources are shown in alphabetical order for quick scanning. Green resourceswill be created (or destroyed and then created if an existing resourceexists), yellow resources are being changed in-place, and red resourceswill be destroyed. Cyan entries are data sources to be read.
Note: You didn't specify an "-out" parameter to save this plan, so when"apply" is called, Terraform can't guarantee this is what will execute.
+ aws_s3_bucket_object.distribution_zip acl: "private" bucket: "veriluma-lambda-functions" content_type: "<computed>" etag: "6b3d110594e3ebe5fa2cc22363cd2b02" key: "mna-create-assessment.zip" source: "testing.zip" storage_class: "<computed>" version_id: "<computed>"
Plan: 1 to add, 0 to change, 0 to destroy.terraform plan -var distribution_zip=$( pwd )/testing.zip
OR
terraform plan -var distribution_zip="$( pwd )/testing.zip"