I have created two subnets for rds but still, I am getting error DB Subnet Group doesn't meet the availability zone coverage requirement. Please add subnets to cover at least 2 availability zones. Current coverage: 1, As I can check my both subnets, even all of my subnets are getting created in the same availability zone. Can you Please guide me
resource "aws_db_subnet_group" "rdssubnet" {
name = "database subnet"
subnet_ids = ["${aws_subnet.rds_subnet.id}","${aws_subnet.rds_subnet1.id}"]
}
#provision the database
resource "aws_db_instance" "database" {
identifier = "database"
instance_class = var.db_instance_type
allocated_storage = var.db_size
engine = "mysql"
multi_az = false
name = "Database "
password = var.rds_password
username = var.rds_user
engine_version = "5.7.00"
skip_final_snapshot = true
db_subnet_group_name = aws_db_subnet_group.rdssubnet.name
vpc_security_group_ids = [aws_security_group.rds.id]