mirror of
https://github.com/netbox-community/netbox-docker.git
synced 2026-01-29 14:11:51 +00:00
Compare commits
6 commits
2e492302a6
...
2f961e13a8
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2f961e13a8 | ||
|
|
1d8a31be83 | ||
|
|
109ef8afd2 | ||
|
|
b329ab9e61 | ||
|
|
56e8af355e | ||
|
|
477decd80a |
|
|
@ -89,7 +89,7 @@ WORKDIR /opt/netbox/netbox
|
||||||
|
|
||||||
# Must set permissions for '/opt/netbox/netbox/media' directory
|
# Must set permissions for '/opt/netbox/netbox/media' directory
|
||||||
# to g+w so that pictures can be uploaded to netbox.
|
# to g+w so that pictures can be uploaded to netbox.
|
||||||
RUN mkdir -p static /opt/unit/state/ /opt/unit/tmp/ \
|
RUN mkdir -p static media /opt/unit/state/ /opt/unit/tmp/ \
|
||||||
&& chown -R unit:root /opt/unit/ media reports scripts \
|
&& chown -R unit:root /opt/unit/ media reports scripts \
|
||||||
&& chmod -R g+w /opt/unit/ media reports scripts \
|
&& chmod -R g+w /opt/unit/ media reports scripts \
|
||||||
&& cd /opt/netbox/ && SECRET_KEY="dummyKeyWithMinimumLength-------------------------" /opt/netbox/venv/bin/python -m mkdocs build \
|
&& cd /opt/netbox/ && SECRET_KEY="dummyKeyWithMinimumLength-------------------------" /opt/netbox/venv/bin/python -m mkdocs build \
|
||||||
|
|
|
||||||
|
|
@ -64,7 +64,8 @@ if '*' not in ALLOWED_HOSTS and 'localhost' not in ALLOWED_HOSTS:
|
||||||
|
|
||||||
# PostgreSQL database configuration. See the Django documentation for a complete list of available parameters:
|
# PostgreSQL database configuration. See the Django documentation for a complete list of available parameters:
|
||||||
# https://docs.djangoproject.com/en/stable/ref/settings/#databases
|
# https://docs.djangoproject.com/en/stable/ref/settings/#databases
|
||||||
DATABASE = {
|
DATABASES = {
|
||||||
|
'default': {
|
||||||
'NAME': environ.get('DB_NAME', 'netbox'), # Database name
|
'NAME': environ.get('DB_NAME', 'netbox'), # Database name
|
||||||
'USER': environ.get('DB_USER', ''), # PostgreSQL username
|
'USER': environ.get('DB_USER', ''), # PostgreSQL username
|
||||||
'PASSWORD': _read_secret('db_password', environ.get('DB_PASSWORD', '')),
|
'PASSWORD': _read_secret('db_password', environ.get('DB_PASSWORD', '')),
|
||||||
|
|
@ -78,6 +79,7 @@ DATABASE = {
|
||||||
'DISABLE_SERVER_SIDE_CURSORS': _environ_get_and_map('DB_DISABLE_SERVER_SIDE_CURSORS', 'False', _AS_BOOL),
|
'DISABLE_SERVER_SIDE_CURSORS': _environ_get_and_map('DB_DISABLE_SERVER_SIDE_CURSORS', 'False', _AS_BOOL),
|
||||||
# Disable the use of server-side cursors transaction pooling
|
# Disable the use of server-side cursors transaction pooling
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
# Redis database settings. Redis is used for caching and for queuing background tasks such as webhook events. A separate
|
# Redis database settings. Redis is used for caching and for queuing background tasks such as webhook events. A separate
|
||||||
# configuration exists for each. Full connection details are required in both sections, and it is strongly recommended
|
# configuration exists for each. Full connection details are required in both sections, and it is strongly recommended
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue