当我在版本 12.24 中运行 terraform plan 时,我收到错误:不支持的参数。
Error: Unsupported argument
on .terraform/modules/app/main.tf line 261, in resource "aws_db_instance" "db_instance":
261: timeouts = {
An argument named "timeouts" is not expected here. Did you mean to define a
block of type "timeouts"?
这是 tf 文件中的代码:
timeouts = {
create = "${var.db_instance_create_timeout}"
update = "${var.db_instance_update_timeout}"
delete = "${var.db_instance_delete_timeout}"
}
我不确定如何解决此错误。
- 通过在超时后删除“=”修复了上述错误。
我也遇到更多错误,需要解决方案:
Error: Unsupported argument
on .terraform/modules/rds/main.tf line 150, in resource "aws_db_parameter_group" "db_parameter_group":
150: parameter = concat(var.parameters, local.parameters[local.parameter_lookup])
An argument named "parameter" is not expected here. Did you mean to define a
block of type "parameter"?
tf 文件中的代码:
parameter = concat(var.parameters, local.parameters[local.parameter_lookup])
如何解决这个问题?