55 lines
1015 B
Terraform
55 lines
1015 B
Terraform
resource "nubes_postgres" "npg" {
|
|
resource_name = "pgtst01"
|
|
|
|
startup_configuration = jsonencode({
|
|
resourceRealm = var.realm
|
|
})
|
|
|
|
cluster_configuration = jsonencode({
|
|
cpu = "500"
|
|
memory = "512"
|
|
replicas = "1"
|
|
disk = "10"
|
|
})
|
|
|
|
access_configuration = jsonencode({
|
|
masterIpSpace = "no-needed"
|
|
masterAccessList = ["10.0.0.0/8"]
|
|
slaveIpSpace = "no-needed"
|
|
slaveAccessList = []
|
|
})
|
|
|
|
postgres_configuration = jsonencode({
|
|
version = "17"
|
|
sslRequired = true
|
|
poolerMaster = false
|
|
poolerSlave = false
|
|
})
|
|
|
|
postgres_conf = jsonencode([
|
|
{
|
|
paramName = "log_connections"
|
|
paramValue = "''"
|
|
}
|
|
])
|
|
|
|
backup_configuration = jsonencode({
|
|
s3Uid = var.s3_uid
|
|
retain = "14"
|
|
schedule = "0 0 * * *"
|
|
})
|
|
|
|
autoscale_configuration = jsonencode({
|
|
enabled = false
|
|
schedule = "0"
|
|
percent = "10"
|
|
quota = "100"
|
|
})
|
|
|
|
operation_timeout = "11m"
|
|
adopt_existing_on_create = true
|
|
}
|
|
|
|
|
|
|