PostgreSQL
The PostgreSQL service connector processes connection requests to a PostgreSQL database.
To secure connections, we support all of the PostgreSQL SSL options that you are familar with. For details, see sslmode.
Unlike other clients, the default |
Configure the service connector
Configure the Secretless Broker to specify where to find your database connection details in the credentials
section of the yaml file. This includes where to find your database's host
, port
, username
, and password
, as well as the sslmode
details, such as the location of any relevant certificates and revocation lists, if applicable.
The options are as follows:
Parameter |
Description |
Required |
---|---|---|
|
Host name of the PostgreSQL server. |
Required |
|
Port of the PostgreSQL server. |
Optional (Default setting is 5432) |
|
Username of the PostgreSQL account. |
Required |
|
Password of the PostgreSQL account. |
Required |
Determines if the connection between the Secretless Broker
and your database is protected by SSL. Defaults to
For details on the supported values of this parameter, see SSL Modes. |
Optional |
|
|
The content of this parameter specifies the client SSL certificate, replacing the default ~/.postgresql/postgresql.crt. This parameter is ignored if an SSL connection is not made. |
Optional |
|
The content of this parameter specifies the SSL certificate authority (CA) certificate(s), replacing the default ~/.postgresql/root.crt. If present, the server's certificate is verified to be signed by one of these authorities. |
Optional |
|
The content of this parameter specifies the secret key used for the client certificate, replacing the default ~/.postgresql/postgresql.key. This parameter is ignored if an SSL connection is not made. |
Optional |
The PostgreSQL documentation website provides detail on the levels of protection provided by different values for the sslmode parameter.
Secretless supports the following SSL modes:
Parameter |
Description |
---|---|
|
Try only a non-SSL connection. |
Default |
Try only an SSL connection. If a root CA file is present, verify the certificate in the same way as if verify-ca was specified. |
|
Try only an SSL connection, and verify that the server certificate is issued by a trusted certificate authority (CA). |
|
Try only an SSL connection, and verify the server certificate against the configured CA certificates (provided in the Secretless configuration via Secretless uses the value of the |
Secretless does not currently support the When |
Examples
sslmode
of require
|
sslmode
of require
|
|
If your certificate is stored in the environment or a secret store rather than a file, you can use the appropriate provider. |