1.7 KiB
NetBox
Inventory and network documentation with a web process, worker, and Valkey.
Kubernetes uses the shared PostgreSQL service at
postgres.database.svc.cluster.local:5432, database and role netbox.
The database and application Secrets must contain the same password.
Media, reports, scripts, and Valkey have persistent storage.
Compose has its own PostgreSQL container and Valkey instances. It publishes the
web UI on 127.0.0.1:8000; its Traefik labels can also expose it while a Docker
proxy is running. Copy .env.example to .env, replace the credentials, and run
docker compose config --quiet before starting it.
First Kubernetes start
Create the namespace and application Secret. Provision the database through the
shared database initializer on a fresh instance, or create the role and database
manually on an existing instance; see PostgreSQL.
The database NetworkPolicy already includes netbox.
Apply the selected application manifests after the database is ready. Startup runs schema migrations, so the probes allow a longer first boot. Inspect web and worker logs before retrying a slow migration.
Settings and backup
configuration/configuration.py is the Compose settings file. Its Kubernetes
copy is embedded in k8s/settings.yaml; keep them aligned.
Back up the database and media together. Keep SECRET_KEY and
API_TOKEN_PEPPER_1: changing them invalidates sessions or API tokens.
A container rollback cannot undo a database migration.
Inspect
From the repository root:
kubectl get pods,svc,pvc -n netbox
kubectl get events -n netbox --sort-by=.metadata.creationTimestamp
See the repository README for deployment selection.