mirror of
https://github.com/netbox-community/netbox.git
synced 2025-07-14 09:51:22 -06:00
Closes #4160: Link to full database configuration parameters in configuration docs
This commit is contained in:
parent
47b15aacef
commit
0c89534bfb
@ -21,7 +21,7 @@ NetBox requires access to a PostgreSQL database service to store data. This serv
|
|||||||
* `PASSWORD` - PostgreSQL password
|
* `PASSWORD` - PostgreSQL password
|
||||||
* `HOST` - Name or IP address of the database server (use `localhost` if running locally)
|
* `HOST` - Name or IP address of the database server (use `localhost` if running locally)
|
||||||
* `PORT` - TCP port of the PostgreSQL service; leave blank for default port (5432)
|
* `PORT` - TCP port of the PostgreSQL service; leave blank for default port (5432)
|
||||||
* `CONN_MAX_AGE` - Number in seconds for Netbox to keep database connections open. 150-300 seconds is typically a good starting point ([more info](https://docs.djangoproject.com/en/stable/ref/databases/#persistent-connections)).
|
* `CONN_MAX_AGE` - Lifetime of a [persistent database connection](https://docs.djangoproject.com/en/stable/ref/databases/#persistent-connections), in seconds (150-300 is recommended)
|
||||||
|
|
||||||
Example:
|
Example:
|
||||||
|
|
||||||
@ -36,6 +36,9 @@ DATABASE = {
|
|||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
!!! note
|
||||||
|
NetBox supports all PostgreSQL database options supported by the underlying Django framework. For a complete list of available parameters, please see [the Django documentation](https://docs.djangoproject.com/en/stable/ref/settings/#databases).
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
## REDIS
|
## REDIS
|
||||||
|
@ -10,7 +10,8 @@
|
|||||||
# Example: ALLOWED_HOSTS = ['netbox.example.com', 'netbox.internal.local']
|
# Example: ALLOWED_HOSTS = ['netbox.example.com', 'netbox.internal.local']
|
||||||
ALLOWED_HOSTS = []
|
ALLOWED_HOSTS = []
|
||||||
|
|
||||||
# PostgreSQL database configuration.
|
# PostgreSQL database configuration. See the Django documentation for a complete list of available parameters:
|
||||||
|
# https://docs.djangoproject.com/en/stable/ref/settings/#databases
|
||||||
DATABASE = {
|
DATABASE = {
|
||||||
'NAME': 'netbox', # Database name
|
'NAME': 'netbox', # Database name
|
||||||
'USER': '', # PostgreSQL username
|
'USER': '', # PostgreSQL username
|
||||||
|
Loading…
Reference in New Issue
Block a user