# PostgreSQL Flexible Server Zone-redundant, with public access off, geo-redundant backup and Entra authentication. ```hcl resource "azurerm_postgresql_flexible_server" "main" { name = "psql-workload" location = var.location resource_group_name = var.resource_group_name version = "16" sku_name = "GP_Standard_D2ds_v5" storage_mb = 65536 backup_retention_days = 14 geo_redundant_backup_enabled = true public_network_access_enabled = false zone = "1" high_availability { mode = "ZoneRedundant" standby_availability_zone = "2" } authentication { active_directory_auth_enabled = true password_auth_enabled = false } } ```