Netbox
Infrastructure resource modelling and documentation tool
Netbox is an infrastructure resource modelling (IRM) application for documenting and managing networks, IP addresses, equipment, and connections. It serves as a source of truth for network infrastructure documentation.
ArgoCD Resource
| Property | Value |
|---|---|
| Kind | Application |
| Name | netbox |
| Namespace | argocd |
| Destination Namespace | netbox |
| Project | infra-services |
| Source Type | Kustomize |
| File Path | k8s/infra-services/argocd/overlays/infra-platform-cluster/apps/netbox.yaml |
Application Definition
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: netbox
labels:
cluster: 'infra-platform-mgmt'
environment: 'prod'
finalizers:
- resources-finalizer.argocd.argoproj.io
annotations:
notifications.argoproj.io/subscribe.on-app-synced.slack: platform-infra-notifications
notifications.argoproj.io/subscribe.on-app-outofsync.slack: platform-infra-notifications
notifications.argoproj.io/subscribe.on-app-sync-failed.slack: platform-infra-notifications
notifications.argoproj.io/subscribe.on-app-degraded.slack: platform-infra-notifications
spec:
syncPolicy:
automated:
prune: true
destination:
namespace: argocd
server: https://kubernetes.default.svc
project: infra-services
source:
path: k8s/infra-services/netbox
repoURL: https://github.com/Titanbay/infra-services
targetRevision: 'main'
Manifest Organisation
The Netbox manifests use a simple Kustomize structure with a base directory:
k8s/infra-services/netbox/
├── kustomization.yaml # Top-level kustomization (sets namespace: netbox)
└── base/
├── kustomization.yaml # Base resources
├── netbox-deployment.yaml # Main Netbox deployment and service
├── netbox-redis.yaml # Redis deployment for caching
├── configmap.yaml # Netbox configuration
├── netbox-secret.yaml # ExternalSecret for credentials
├── netbox-service-account.yaml # Service account
└── secret-store.yaml # GCP Secret Manager SecretStore
Key Components
| Resource | Purpose |
|---|---|
| Deployment | Netbox application container |
| Redis | Session caching and queuing |
| ConfigMap | Database and Redis connection settings |
| ExternalSecret | Credentials from GCP Secret Manager |
| SecretStore | GCP Secret Manager integration |
How to Update
Modifying Configuration
- Edit the appropriate file in
k8s/infra-services/netbox/base/ - Commit and push to
main - ArgoCD auto-syncs the changes
Updating Netbox Version
- Update the container image in
base/netbox-deployment.yaml - Review the Netbox changelog
- Commit and push to
main
Secrets Management
Netbox credentials are managed via External Secrets:
| Secret | Source |
|---|---|
| Database credentials | GCP Secret Manager |
| Secret key | GCP Secret Manager |
The SecretStore in base/secret-store.yaml configures access to GCP Secret Manager.
Notifications
The Application sends Slack notifications to #platform-infra-notifications for:
- Sync success
- Out of sync detection
- Sync failures
- Degraded health