mirror of
https://github.com/netbox-community/netbox-docker.git
synced 2025-12-12 22:56:48 +00:00
Compare commits
4 commits
8ccce778ae
...
b3d38db38b
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b3d38db38b | ||
|
|
b97c177df8 | ||
|
|
67eff20f7d | ||
|
|
7c22dd8656 |
|
|
@ -46,8 +46,10 @@ RUN \
|
||||||
ARG FROM
|
ARG FROM
|
||||||
FROM ${FROM} AS main
|
FROM ${FROM} AS main
|
||||||
|
|
||||||
|
ARG NGINX_KEYRING_SHA256_SUM=7d3d5a7adf37e17d6882e2f6f55324b9a8f978ef3c99c50fe801af67c9847c91
|
||||||
|
# hadolint ignore=DL3020
|
||||||
|
ADD --chown=0:0 --chmod=444 --checksum=sha256:${NGINX_KEYRING_SHA256_SUM} https://unit.nginx.org/keys/nginx-keyring.gpg /usr/share/keyrings/nginx-keyring.gpg
|
||||||
COPY docker/unit.list /etc/apt/sources.list.d/unit.list
|
COPY docker/unit.list /etc/apt/sources.list.d/unit.list
|
||||||
ADD --chmod=444 --chown=0:0 https://unit.nginx.org/keys/nginx-keyring.gpg /usr/share/keyrings/nginx-keyring.gpg
|
|
||||||
RUN export DEBIAN_FRONTEND=noninteractive \
|
RUN export DEBIAN_FRONTEND=noninteractive \
|
||||||
&& apt-get update -qq \
|
&& apt-get update -qq \
|
||||||
&& apt-get upgrade \
|
&& apt-get upgrade \
|
||||||
|
|
@ -79,7 +81,6 @@ COPY ${NETBOX_PATH} /opt/netbox
|
||||||
COPY docker/configuration.docker.py /opt/netbox/netbox/netbox/configuration.py
|
COPY docker/configuration.docker.py /opt/netbox/netbox/netbox/configuration.py
|
||||||
COPY docker/ldap_config.docker.py /opt/netbox/netbox/netbox/ldap_config.py
|
COPY docker/ldap_config.docker.py /opt/netbox/netbox/netbox/ldap_config.py
|
||||||
COPY docker/docker-entrypoint.sh /opt/netbox/docker-entrypoint.sh
|
COPY docker/docker-entrypoint.sh /opt/netbox/docker-entrypoint.sh
|
||||||
COPY docker/housekeeping.sh /opt/netbox/housekeeping.sh
|
|
||||||
COPY docker/launch-netbox.sh /opt/netbox/launch-netbox.sh
|
COPY docker/launch-netbox.sh /opt/netbox/launch-netbox.sh
|
||||||
COPY configuration/ /etc/netbox/config/
|
COPY configuration/ /etc/netbox/config/
|
||||||
COPY docker/nginx-unit.json /etc/unit/
|
COPY docker/nginx-unit.json /etc/unit/
|
||||||
|
|
|
||||||
|
|
@ -28,15 +28,6 @@ services:
|
||||||
start_period: 40s
|
start_period: 40s
|
||||||
timeout: 3s
|
timeout: 3s
|
||||||
interval: 15s
|
interval: 15s
|
||||||
netbox-housekeeping:
|
|
||||||
<<: *netbox
|
|
||||||
command:
|
|
||||||
- /opt/netbox/housekeeping.sh
|
|
||||||
healthcheck:
|
|
||||||
test: ps -aux | grep -v grep | grep -q housekeeping || exit 1
|
|
||||||
start_period: 40s
|
|
||||||
timeout: 3s
|
|
||||||
interval: 15s
|
|
||||||
|
|
||||||
postgres:
|
postgres:
|
||||||
image: docker.io/postgres:17-alpine
|
image: docker.io/postgres:17-alpine
|
||||||
|
|
|
||||||
|
|
@ -31,18 +31,6 @@ services:
|
||||||
start_period: 20s
|
start_period: 20s
|
||||||
timeout: 3s
|
timeout: 3s
|
||||||
interval: 15s
|
interval: 15s
|
||||||
netbox-housekeeping:
|
|
||||||
<<: *netbox
|
|
||||||
depends_on:
|
|
||||||
netbox:
|
|
||||||
condition: service_healthy
|
|
||||||
command:
|
|
||||||
- /opt/netbox/housekeeping.sh
|
|
||||||
healthcheck:
|
|
||||||
test: ps -aux | grep -v grep | grep -q housekeeping || exit 1
|
|
||||||
start_period: 20s
|
|
||||||
timeout: 3s
|
|
||||||
interval: 15s
|
|
||||||
|
|
||||||
# postgres
|
# postgres
|
||||||
postgres:
|
postgres:
|
||||||
|
|
|
||||||
|
|
@ -1,8 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
SLEEP_SECONDS=${HOUSEKEEPING_INTERVAL:=86400}
|
|
||||||
echo "Interval set to ${SLEEP_SECONDS} seconds"
|
|
||||||
while true; do
|
|
||||||
date
|
|
||||||
/opt/netbox/venv/bin/python /opt/netbox/netbox/manage.py housekeeping
|
|
||||||
sleep "${SLEEP_SECONDS}s"
|
|
||||||
done
|
|
||||||
1
env/netbox.env
vendored
1
env/netbox.env
vendored
|
|
@ -15,7 +15,6 @@ EMAIL_USERNAME=netbox
|
||||||
EMAIL_USE_SSL=false
|
EMAIL_USE_SSL=false
|
||||||
EMAIL_USE_TLS=false
|
EMAIL_USE_TLS=false
|
||||||
GRAPHQL_ENABLED=true
|
GRAPHQL_ENABLED=true
|
||||||
HOUSEKEEPING_INTERVAL=86400
|
|
||||||
MEDIA_ROOT=/opt/netbox/netbox/media
|
MEDIA_ROOT=/opt/netbox/netbox/media
|
||||||
METRICS_ENABLED=false
|
METRICS_ENABLED=false
|
||||||
REDIS_CACHE_DATABASE=1
|
REDIS_CACHE_DATABASE=1
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue