Generate Kubernetes architecture diagrams from Kubernetes manifest files, kustomization files, Helm charts, helmfiles, and actual cluster state
Generate Kubernetes architecture diagrams from Kubernetes manifest files, kustomization files, Helm charts, helmfiles, and actual cluster state
Generate Kubernetes architecture diagrams from Kubernetes manifest files, kustomization files, Helm charts, helmfile descriptors, and actual cluster state.
There are several tools to generate Kubernetes architecture diagrams, see here for a detailed list and comparison. Compared to these existing tools, the main originalities of KubeDiagrams are the support of:
KubeDiagrams is available as a Python package in PyPI, a container image in DockerHub, a kubectl plugin, a Nix flake, and a GitHub Action, see here for more details.
An Online KubeDiagrams Service is freely available at https://kubediagrams.lille.inria.fr/.
Read Real-World Use Cases and What do they say about it to discover how KubeDiagrams is really used and appreciated.
Try it on your own Kubernetes manifests, Helm charts, helmfiles, and actual cluster state!
Architecture diagram for official Kubernetes WordPress tutorial manifests:
Architecture diagram for official Kubernetes ZooKeeper tutorial manifests:
Architecture diagram of a deployed Cassandra instance:
Architecture diagram for Train Ticket:A Benchmark Microservice System:
Architecture diagram of the Minikube Ingress Addon:
Architecture diagram for the Kube Prometheus Stack chart:
Architecture diagram for free5gc-k8s manifests:
Architecture diagram for open5gs-k8s manifests:
Architecture diagram for the Towards5GS-helm chart:
Architecture diagram for a deployed CronJob instance:
Architecture diagram for NetworkPolicy resources:
Architecture diagram for an Argo CD example:
Architecture diagram for an Argo Events example:
Many other architecture diagrams are available into examples/.
Following software must be installed:
You could use KubeDiagrams directly from your favorite Web browser here.
Following command installs KubeDiagrams and all its Python dependencies, i.e., PyYAML, Diagrams, and graphviz2drawio.
# using pip (pip3)
pip install KubeDiagramsAlternatively, you can install via Nix:
nix shell github:philippemerle/KubeDiagramsKubeDiagrams container images are available in Docker Hub. You can download the latest container image via:
docker pull philippemerle/kubediagramsYou can start directly from source:
# clone the KubeDiagrams repository
git clone https://github.com/philippemerle/KubeDiagrams.git
# install required Python packages
pip install PyYAML diagrams graphviz2drawio
# make KubeDiagrams commands available into $PATH
PATH=$(pwd)/KubeDiagrams/bin:$PATHTo use KubeDiagrams from Windows operating system, only the container image is supported currently.
[!NOTE]
Any contribution would be welcome to translate KubeDiagrams' Unix-based scripts to Windows-based scripts.
KubeDiagrams provides two commands: kube-diagrams and helm-diagrams.
kube-diagramskube-diagrams generates a Kubernetes architecture diagram from one or several Kubernetes manifest files.
…kube-diagrams reads Kubernetes manifests from the standard input when filename is equals to -.
Examples:
…kubectl Plugin SupportYou can use KubeDiagrams as a kubectl plugin as well for a more integrated Kubernetes workflow. This allows you to run commands like:
kubectl diagrams all -o diagram.pngTo enable this, simply symlink or copy the kubectl-diagrams script onto your $PATH:
ln -s $(which kubectl-diagrams) /usr/local/bin/kubectl-diagrams[!NOTE]
You will also already need
kube-diagramson your$PATHas well for this to work.
You can alternatively install it via Nix:
nix shell github:philippemerle/KubeDiagrams#kubectl-diagramshelm-diagramshelm-diagrams generates a Kubernetes architecture diagram from an Helm chart.
…[!NOTE]
helm-diagramsrequires that thehelmcommand was installed.
Examples:
# generate a diagram for the Helm chart 'cert-manager' available in HTTP repository 'charts.jetstack.io'
helm-diagrams https://charts.jetstack.io/cert-manager
# generate a diagram for the Helm chart 'argo-cd' available in OCI repository 'ghcr.io'
helm-diagrams oci://ghcr.io/argoproj/argo-helm/argo-cd
# generate a diagram for the Helm chart 'some-chart' available locally
helm-diagrams some-path/some-chartKubeDiagrams images are available in Docker Hub.
…You can use KubeDiagrams (and Helm Diagrams) in your GitHub Action workflows.
…Action philippemerle/KubeDiagrams@main is available here.
The KubeDiagrams Plugin for JetBrains IDEs is available here.
KubeDiagrams supports the following 51 Kubernetes resource types:
| Kind | ApiGroup | Versions | Icon |
|---|
No open issues yet, or sync has not completed.