diff --git a/examples/postgresql-with-cross-region-failover/main.tf b/examples/postgresql-with-cross-region-failover/main.tf index ec047dbb..07ac5a87 100644 --- a/examples/postgresql-with-cross-region-failover/main.tf +++ b/examples/postgresql-with-cross-region-failover/main.tf @@ -52,7 +52,7 @@ module "pg1" { name = var.pg_name_1 random_instance_name = true project_id = var.project_id - database_version = "POSTGRES_14" + database_version = "POSTGRES_17" region = local.region_1 edition = local.edition @@ -164,7 +164,7 @@ module "pg2" { name = var.pg_name_2 random_instance_name = true project_id = var.project_id - database_version = "POSTGRES_14" + database_version = "POSTGRES_17" region = local.region_2 edition = local.edition diff --git a/modules/postgresql/variables.tf b/modules/postgresql/variables.tf index 0d50fd54..26453f2d 100644 --- a/modules/postgresql/variables.tf +++ b/modules/postgresql/variables.tf @@ -49,7 +49,7 @@ variable "database_version" { validation { condition = (length(var.database_version) >= 9 && ((upper(substr(var.database_version, 0, 9)) == "POSTGRES_") && can(regex("^\\d+(?:_?\\d)*$", substr(var.database_version, 9, -1))))) || can(regex("^\\d+(?:_?\\d)*$", var.database_version)) - error_message = "The specified database version is not a valid representaion of database version. Valid database versions should be like the following patterns:- \"9_6\", \"postgres_9_6\", \"POSTGRES_14\" or \"POSTGRES_15\"" + error_message = "The specified database version is not a valid representation of database version. Valid database versions should be like the following patterns:- \"9_6\", \"postgres_9_6\", \"POSTGRES_14\", \"POSTGRES_15\", \"POSTGRES_17\" or \"POSTGRES_17\"" } }