You've already forked netbox
Compare commits
4 Commits
Author | SHA1 | Date | |
---|---|---|---|
a15384132e | |||
5f09b5fd2c | |||
35ae265805 | |||
49ee613f95 |
@@ -69,6 +69,12 @@ services:
|
|||||||
- traefik.http.routers.https-${TRAEFIK_ROUTER}.tls.certresolver=${TRAEFIK_CERTRESOLVER}
|
- traefik.http.routers.https-${TRAEFIK_ROUTER}.tls.certresolver=${TRAEFIK_CERTRESOLVER}
|
||||||
# specify a service so a custom port can be used
|
# specify a service so a custom port can be used
|
||||||
- traefik.http.services.${TRAEFIK_SERVICE}.loadbalancer.server.port=${TRAEFIK_SERVICE_PORT}
|
- traefik.http.services.${TRAEFIK_SERVICE}.loadbalancer.server.port=${TRAEFIK_SERVICE_PORT}
|
||||||
|
### Section DIUN
|
||||||
|
- diun.enable=${DIUN_NETBOX_ENABLE}
|
||||||
|
- diun.watch_repo=${DIUN_NETBOX_WATCHREPO}
|
||||||
|
- diun.sort_tags=${DIUN_NETBOX_SORTALGO}
|
||||||
|
- diun.include_tags=${DIUN_NETBOX_INCLUDE}
|
||||||
|
- diun.exclude_tags=${DIUN_NETBOX_EXCLUDE}
|
||||||
networks:
|
networks:
|
||||||
- internal
|
- internal
|
||||||
- traefik
|
- traefik
|
||||||
@@ -114,6 +120,13 @@ services:
|
|||||||
- POSTGRES_DB=${PSQL_NAME}
|
- POSTGRES_DB=${PSQL_NAME}
|
||||||
- POSTGRES_USER=${PSQL_USER}
|
- POSTGRES_USER=${PSQL_USER}
|
||||||
- POSTGRES_PASSWORD=${PSQL_PASS}
|
- POSTGRES_PASSWORD=${PSQL_PASS}
|
||||||
|
labels:
|
||||||
|
### Section DIUN
|
||||||
|
- diun.enable=${DIUN_POSTGRES_ENABLE}
|
||||||
|
- diun.watch_repo=${DIUN_POSTGRES_WATCHREPO}
|
||||||
|
- diun.sort_tags=${DIUN_POSTGRES_SORTALGO}
|
||||||
|
- diun.include_tags=${DIUN_POSTGRES_INCLUDE}
|
||||||
|
- diun.exclude_tags=${DIUN_POSTGRES_EXCLUDE}
|
||||||
networks:
|
networks:
|
||||||
- internal
|
- internal
|
||||||
volumes:
|
volumes:
|
||||||
@@ -128,6 +141,13 @@ services:
|
|||||||
- redis-server --appendonly yes --requirepass $$REDIS_PASSWORD
|
- redis-server --appendonly yes --requirepass $$REDIS_PASSWORD
|
||||||
environment:
|
environment:
|
||||||
- REDIS_PASSWORD=${REDIS_PASS}
|
- REDIS_PASSWORD=${REDIS_PASS}
|
||||||
|
labels:
|
||||||
|
### Section DIUN
|
||||||
|
- diun.enable=${DIUN_REDIS_ENABLE}
|
||||||
|
- diun.watch_repo=${DIUN_REDIS_WATCHREPO}
|
||||||
|
- diun.sort_tags=${DIUN_REDIS_SORTALGO}
|
||||||
|
- diun.include_tags=${DIUN_REDIS_INCLUDE}
|
||||||
|
- diun.exclude_tags=${DIUN_REDIS_EXCLUDE}
|
||||||
networks:
|
networks:
|
||||||
- internal
|
- internal
|
||||||
volumes:
|
volumes:
|
||||||
|
17
env.example
17
env.example
@@ -35,6 +35,23 @@ TRAEFIK_CERTRESOLVER=letsencrypt
|
|||||||
TRAEFIK_SERVICE=netbox_example_com
|
TRAEFIK_SERVICE=netbox_example_com
|
||||||
TRAEFIK_SERVICE_PORT=8080
|
TRAEFIK_SERVICE_PORT=8080
|
||||||
|
|
||||||
|
# DIUN
|
||||||
|
DIUN_NETBOX_ENABLE=true
|
||||||
|
DIUN_NETBOX_WATCHREPO=true
|
||||||
|
DIUN_NETBOX_SORTALGO=semver
|
||||||
|
DIUN_NETBOX_INCLUDE=v[0-9]\.[0-9]\.[0-9]-[0-9]\.[0-9]\.[0-9]
|
||||||
|
DIUN_NETBOX_EXCLUDE=
|
||||||
|
DIUN_POSTGRES_ENABLE=true
|
||||||
|
DIUN_POSTGRES_WATCHREPO=true
|
||||||
|
DIUN_POSTGRES_SORTALGO=semver
|
||||||
|
DIUN_POSTGRES_INCLUDE=v[0-9]\.[0-9]\.[0-9]-[0-9]\.[0-9]\.[0-9]
|
||||||
|
DIUN_POSTGRES_EXCLUDE=
|
||||||
|
DIUN_REDIS_ENABLE=true
|
||||||
|
DIUN_REDIS_WATCHREPO=true
|
||||||
|
DIUN_REDIS_SORTALGO=semver
|
||||||
|
DIUN_REDIS_INCLUDE=v[0-9]\.[0-9]\.[0-9]-[0-9]\.[0-9]\.[0-9]
|
||||||
|
DIUN_REDIS_EXCLUDE=
|
||||||
|
|
||||||
# PostgreSQL
|
# PostgreSQL
|
||||||
PSQL_VERSION=14.5-alpine3.16
|
PSQL_VERSION=14.5-alpine3.16
|
||||||
PSQL_DATA=./data/postgres
|
PSQL_DATA=./data/postgres
|
||||||
|
14
post-installation.sh
Executable file
14
post-installation.sh
Executable file
@@ -0,0 +1,14 @@
|
|||||||
|
#/usr/bin/env bash
|
||||||
|
set -e
|
||||||
|
|
||||||
|
# Search or ask for .env file
|
||||||
|
ENV_FILE=".env"
|
||||||
|
while [ ! -f "${ENV_FILE}" ]; do
|
||||||
|
read -p "\"${ENV_FILE}\" file does not exist, please type your env file: " ENV_FILE
|
||||||
|
done
|
||||||
|
|
||||||
|
# Disable superuser config in environment variable, it's now in the database
|
||||||
|
sed -i "s/NETBOX_SUPERUSER_EMAIL=.*/NETBOX_SUPERUSER_EMAIL=/" "${ENV_FILE}"
|
||||||
|
sed -i "s/NETBOX_SUPERUSER_NAME=.*/NETBOX_SUPERUSER_NAME=/" "${ENV_FILE}"
|
||||||
|
sed -i "s/NETBOX_SUPERUSER_PASS=.*/NETBOX_SUPERUSER_PASS=/" "${ENV_FILE}"
|
||||||
|
sed -i "s/NETBOX_SKIP_SUPERUSER=/NETBOX_SKIP_SUPERUSER=true/" "${ENV_FILE}"
|
Reference in New Issue
Block a user