_This issue was originally opened by @a9tm as hashicorp/terraform#18009. It was migrated here as a result of the provider split. The original body of the issue is below._
I'm trying to launch a RDS Postgres instance but failed.
Terraform v0.11.7
+ provider.aws v1.17.0
resource "aws_db_subnet_group" "postgres" {
name = "postgres-subnets"
subnet_ids = ["${var.net_priv_a_var}", "${var.net_priv_b_var}"]
tags {
Name = "Postgres DB subnet group"
}
}
resource "aws_db_instance" "postgres" {
allocated_storage = 10
storage_type = "gp2"
engine = "postgresql"
db_subnet_group_name = "${aws_db_subnet_group.postgres.id}"
engine_version = "9.6.6"
instance_class = "db.t2.small"
name = "***"
username = "***"
password = "***"
}
RDS instance be created
* aws_db_instance.postgres: Error creating DB Instance: InvalidParameterValue: Invalid DB engine
status code: 400, request id: 8f7e8cd3-94fb-45a6-b295-xxx
Hi,
Have you tried with postgres engine (instead of postgresql) ?
Valid engines are listed here (https://docs.aws.amazon.com/cli/latest/reference/rds/create-db-instance.html), at the --engine section
postgres works instead of postgresql, I hope terraform docs mention this piece. On the other thought, I wonder why it's not mys instead of mysql?
This is how AWS decided to call it. Terraform AWS provider is using AWS SDK.
The complete list of engines is listed here under "Engine" section.
As @antonbabenko rightly mentioned we have the link to supported engines in relevant docs.
I don't believe there's more we can do at this point so I'm going to close this.
Thanks
usage:
engine = "postgres"
Should fix. @radeksimko thanks for closing :)
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 feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks!
Most helpful comment
postgresworks instead of postgresql, I hope terraform docs mention this piece. On the other thought, I wonder why it's notmysinstead ofmysql?