You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
-/+ module.layer_authorizer.aws_lambda_layer_version.layer (new resource required)
id: "arn:aws:lambda:us-east-1:x-dev-authorizer-layer:17" => <computed> (forces new resource)
arn: "arn:aws:lambda:us-east-1:x-dev-authorizer-layer:17" => <computed>
compatible_runtimes.#: "1" => "1"
compatible_runtimes.3898948262: "nodejs8.10" => "nodejs8.10"
created_date: "2019-04-22T05:45:24.106+0000" => <computed>
layer_arn: "arn:aws:lambda:us-east-1:x:x-dev-authorizer-layer" => <computed>
layer_name: "x-dev-authorizer-layer" => "x-dev-authorizer-layer"
s3_bucket: "x-dev-artifacts" => "x-dev-artifacts"
s3_key: "layers/authorizer.zip" => "layers/authorizer.zip"
s3_object_version: "x" => "${data.aws_s3_bucket_object.layer.version_id}" (forces new resource)
source_code_hash: "x" => <computed>
source_code_size: "x" => <computed>
version: "x" => <computed>
s3_object_version: "x" --> Same as previous
Expected Behavior
The computed "${data.aws_s3_bucket_object.layer.version_id}" version_id should see the same value and not force a new resource.
Actual Behavior
Even though the previous s3_object_version is the same, the layer is recreated and versioned.
Steps to Reproduce
Configuration above, having a data lookup on an existing S3 object and grabbing the version_id... then attaching that to the s3_object_version argument in aws_lambda_layer_version.
Important Factoids
Versioning is enabled, I've confirmed the output of the S3 object data matches the layer object reference.
Appears this is due to a depends_on with a null_resource outside of this... Seems a data resource doesn't compute if the attached null resource doesn't trigger, ugh
Community Note
Terraform Version
Terraform v0.11.13
Affected Resource(s)
aws_lambda_layer_version
Terraform Configuration Files
Debug Output
Panic Output
s3_object_version: "x" --> Same as previous
Expected Behavior
The computed
"${data.aws_s3_bucket_object.layer.version_id}"
version_id should see the same value and not force a new resource.Actual Behavior
Even though the previous
s3_object_version
is the same, the layer is recreated and versioned.Steps to Reproduce
Configuration above, having a data lookup on an existing S3 object and grabbing the version_id... then attaching that to the
s3_object_version
argument inaws_lambda_layer_version
.Important Factoids
Versioning is enabled, I've confirmed the output of the S3 object data matches the layer object reference.
References
Similar, but not the same issue: #7552
My issue will ALWAYS recompute and force a new resource, unlike that above issue which
The text was updated successfully, but these errors were encountered: