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
Terraform v1.6.2
on windows_amd64
+ provider registry.terraform.io/hashicorp/aws v5.22.0
Terraform Configuration Files
import {
id = "xxxxxx"
to = aws_lambda_function.xxxxxx
}
Debug Output
will provide if needed
Expected Behavior
Should be able to create generated.tf
Actual Behavior
Error: Invalid combination of arguments
with aws_lambda_function.DeviceUsageJob,
on generated.tf line 16:
(source code not available)
"s3_bucket": one of filename,image_uri,s3_bucket must be specified
Steps to Reproduce
terraform init
terraform plan -generate-config-out=generated.tf
Additional Context
It is generating a 'generated.tf' file in which, for some Lambda functions, the creation configuration includes 's3_bucket' without specifying one of filename, image_uri, or s3_bucket. However, for some other Lambda functions, it does not generate the configuration and gives an error stating that 's3_bucket' must be specified as one of filename, image_uri, or `s3_bucket."
References
No response
The text was updated successfully, but these errors were encountered:
The error here is again from the provider, not from Terraform itself. The state returned by the provider for the aws_lambda_function resource appears to be missing values which would be required if it were written in the configuration. Since Terraform cannot guess what these values should be, it is up to the provider to return them in the read state. While the resource implementation would need to be changed in the provider to allow for config generation, the normal import process should work as expected if you create a resource block for the aws_lambda_function manually.
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.
Terraform Version
Terraform Configuration Files
import {
id = "xxxxxx"
to = aws_lambda_function.xxxxxx
}
Debug Output
will provide if needed
Expected Behavior
Should be able to create generated.tf
Actual Behavior
Error: Invalid combination of arguments
with aws_lambda_function.DeviceUsageJob,
on generated.tf line 16:
(source code not available)
"s3_bucket": one of
filename,image_uri,s3_bucket
must be specifiedSteps to Reproduce
terraform init
terraform plan -generate-config-out=generated.tf
Additional Context
It is generating a 'generated.tf' file in which, for some Lambda functions, the creation configuration includes 's3_bucket' without specifying one of filename, image_uri, or s3_bucket. However, for some other Lambda functions, it does not generate the configuration and gives an error stating that 's3_bucket' must be specified as one of filename, image_uri, or `s3_bucket."
References
No response
The text was updated successfully, but these errors were encountered: