From d258f2c2111cda48d4bfbb9af30729b288e5ec54 Mon Sep 17 00:00:00 2001 From: ziyeqf Date: Tue, 17 Jan 2023 16:53:58 +0800 Subject: [PATCH 1/2] add default value for `authentication.active_directory_auth_enabled` and `authentication.password_auth_enabled` --- .../services/postgres/postgresql_flexible_server_resource.go | 2 ++ website/docs/r/postgresql_flexible_server.html.markdown | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/internal/services/postgres/postgresql_flexible_server_resource.go b/internal/services/postgres/postgresql_flexible_server_resource.go index ce882527a5c3..3e7c90c86021 100644 --- a/internal/services/postgres/postgresql_flexible_server_resource.go +++ b/internal/services/postgres/postgresql_flexible_server_resource.go @@ -86,10 +86,12 @@ func resourcePostgresqlFlexibleServer() *pluginsdk.Resource { "active_directory_auth_enabled": { Type: pluginsdk.TypeBool, Optional: true, + Default: false, }, "password_auth_enabled": { Type: pluginsdk.TypeBool, Optional: true, + Default: true, }, "tenant_id": { Type: pluginsdk.TypeString, diff --git a/website/docs/r/postgresql_flexible_server.html.markdown b/website/docs/r/postgresql_flexible_server.html.markdown index d4329c7cb098..50ee5c993205 100644 --- a/website/docs/r/postgresql_flexible_server.html.markdown +++ b/website/docs/r/postgresql_flexible_server.html.markdown @@ -132,9 +132,9 @@ The following arguments are supported: An `authentication` block supports the following: -* `active_directory_auth_enabled` - (Optional) Whether or not Active Directory authentication is allowed to access the PostgreSQL Flexible Server. +* `active_directory_auth_enabled` - (Optional) Whether or not Active Directory authentication is allowed to access the PostgreSQL Flexible Server. Defaults to `true`. -* `password_auth_enabled` - (Optional) Whether or not password authentication is allowed to access the PostgreSQL Flexible Server. +* `password_auth_enabled` - (Optional) Whether or not password authentication is allowed to access the PostgreSQL Flexible Server. Defaults to `false`. * `tenant_id` - (Optional) The Tenant ID of the Azure Active Directory which is used by the Active Directory authentication. `active_directory_auth_enabled` must be set to `true`. From 35b6f66eb32f620c470a7e154f5705c5c2db2dc7 Mon Sep 17 00:00:00 2001 From: Matthew Frahry Date: Tue, 31 Jan 2023 10:14:38 -0800 Subject: [PATCH 2/2] Update postgresql_flexible_server.html.markdown --- website/docs/r/postgresql_flexible_server.html.markdown | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/website/docs/r/postgresql_flexible_server.html.markdown b/website/docs/r/postgresql_flexible_server.html.markdown index 50ee5c993205..fa589ec6ed28 100644 --- a/website/docs/r/postgresql_flexible_server.html.markdown +++ b/website/docs/r/postgresql_flexible_server.html.markdown @@ -132,9 +132,9 @@ The following arguments are supported: An `authentication` block supports the following: -* `active_directory_auth_enabled` - (Optional) Whether or not Active Directory authentication is allowed to access the PostgreSQL Flexible Server. Defaults to `true`. +* `active_directory_auth_enabled` - (Optional) Whether or not Active Directory authentication is allowed to access the PostgreSQL Flexible Server. Defaults to `false`. -* `password_auth_enabled` - (Optional) Whether or not password authentication is allowed to access the PostgreSQL Flexible Server. Defaults to `false`. +* `password_auth_enabled` - (Optional) Whether or not password authentication is allowed to access the PostgreSQL Flexible Server. Defaults to `true`. * `tenant_id` - (Optional) The Tenant ID of the Azure Active Directory which is used by the Active Directory authentication. `active_directory_auth_enabled` must be set to `true`.