diff --git a/builtin/providers/postgresql/provider.go b/builtin/providers/postgresql/provider.go index 8a8da8c8f4..308c11f616 100644 --- a/builtin/providers/postgresql/provider.go +++ b/builtin/providers/postgresql/provider.go @@ -38,7 +38,7 @@ func Provider() terraform.ResourceProvider { "ssl_mode": &schema.Schema{ Type: schema.TypeString, Optional: true, - Default: "require", + Default: "prefer", Description: "Connection mode for postgresql server", }, }, diff --git a/website/source/docs/providers/postgresql/index.html.markdown b/website/source/docs/providers/postgresql/index.html.markdown index 0689e0ddc6..87d0ba87fa 100644 --- a/website/source/docs/providers/postgresql/index.html.markdown +++ b/website/source/docs/providers/postgresql/index.html.markdown @@ -59,7 +59,9 @@ resource "postgresql_database" "my_db2" { The following arguments are supported: * `host` - (Required) The address for the postgresql server connection. -* `port` - (Optional) The port for the postgresql server connection. (Default 5432) +* `port` - (Optional) The port for the postgresql server connection. The default is `5432`. * `username` - (Required) Username for the server connection. * `password` - (Optional) Password for the server connection. -* `ssl_mode` - (Optional) Set connection mode for postgresql server (Default "require", more options [lib/pq documentations](https://godoc.org/github.com/lib/pq)). \ No newline at end of file +* `ssl_mode` - (Optional) Set the priority for an SSL connection to the server. + The default is `prefer`; the full set of options and their implications + can be seen [in the libpq SSL guide](http://www.postgresql.org/docs/9.4/static/libpq-ssl.html#LIBPQ-SSL-PROTECTION).