Skip to content

Commit d43d5af

Browse files
committed
docs: postgres environment variables
1 parent 1426452 commit d43d5af

1 file changed

Lines changed: 31 additions & 0 deletions

File tree

docs/reference/environment-variables.md

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -310,6 +310,36 @@ Comma-separated list of URIs. Configures the [`script-src`][mdn-csp-script-src]
310310

311311
Comma-separated list of URIs. Configures the [`style-src`][mdn-csp-style-src] Content Security Policy directive.
312312

313+
## PostgreSQL
314+
315+
!!! tldr "`postgres` Docker image docs"
316+
317+
The official PostgreSQL Docker image has more on available [`postgres` environment variables][postgres]
318+
319+
### `PGWEB_PORT`
320+
321+
The port to serve a (local only) [`pgweb`](https://sosedoff.github.io/pgweb/) service on.
322+
323+
### `POSTGRES_DB`
324+
325+
Used to define a different name for the default database that is created when the image is first started. If it is not specified, then the value of [`POSTGRES_USER`](#postgres_user) will be used.
326+
327+
### `POSTGRES_HOSTNAME`
328+
329+
The hostname of the (local) PostgreSQL Docker service, which is usually just the name of the service itself (`postgres`). Used by e.g. `pgweb` to establish a connection. Or the hostname of a cloud-based PostgreSQL service for e.g. Django to establish a connection.
330+
331+
### `POSTGRES_PASSWORD`
332+
333+
Required to use the (local) PostgreSQL Docker service. It must not be empty or undefined. This environment variable sets the superuser password for PostgreSQL.
334+
335+
### `POSTGRES_PORT`
336+
337+
The port exposed by the (local) PostgreSQL Docker service. Or the port on which to connect to a cloud-based PostgreSQL service.
338+
339+
### `POSTGRES_USER`
340+
341+
Used in conjunction with [`POSTGRES_PASSWORD`](#postgres_password) to set a user and its password. This variable will create the specified user with superuser power.
342+
313343
## reCAPTCHA
314344

315345
!!! tldr "reCAPTCHA docs"
@@ -413,6 +443,7 @@ The default is `0.0` (i.e. no transactions are tracked).
413443
[mdn-csp-frame-src]: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/frame-src
414444
[mdn-csp-script-src]: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/script-src
415445
[mdn-csp-style-src]: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/style-src
446+
[postgres]: https://hub.docker.com/_/postgres/#environment-variables
416447
[recaptcha]: https://developers.google.com/recaptcha
417448
[recaptcha-intro]: https://developers.google.com/recaptcha/intro
418449
[recaptcha-verify]: https://developers.google.com/recaptcha/docs/verify

0 commit comments

Comments
 (0)