https://github.com/Trois-Six/k8s-diagrams
Create diagrams from the Kubernetes API with go-diagrams.
https://github.com/Trois-Six/k8s-diagrams
diagrams kubernetes
Last synced: 6 months ago
JSON representation
Create diagrams from the Kubernetes API with go-diagrams.
- Host: GitHub
- URL: https://github.com/Trois-Six/k8s-diagrams
- Owner: trois-six
- License: apache-2.0
- Created: 2021-04-26T13:44:26.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2024-02-15T13:35:04.000Z (over 1 year ago)
- Last Synced: 2024-11-15T00:11:38.311Z (7 months ago)
- Topics: diagrams, kubernetes
- Language: Go
- Homepage:
- Size: 1.05 MB
- Stars: 141
- Watchers: 3
- Forks: 13
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Kubernetes diagrams
k8s-diagrams creates diagrams from your kubernetes clusters.
You just have to provide a namespace (or not), and you get a picture from the current state of your cluster. For now it only suppports namespaces, deployments, replicaSets, daemonSets, statefulSets, pods, services and ingresses. I may add other k8s API objects in the future...## How do I build it?
```sh
$ make build
```## Usage
```sh
$ ./k8s-diagrams --help ✔
NAME:
k8s-diagrams - Create diagram from the Kubernetes API.USAGE:
k8s-diagrams [global options] command [command options] [arguments...]COMMANDS:
help, h Shows a list of commands or help for one commandGLOBAL OPTIONS:
--namespace value, -n value The namespace we want to draw. (default: "default") [$KUBECTL_NAMESPACE]
--kubeconfig value, -c value The path to your kube config file. [$KUBECONFIG]
--outputFilename value, -o value The output filename. (default: "k8s")
--outputDirectory value, -d value The output directory. (default: "diagrams")
--label value, -l value The diagram label. (default: "Kubernetes")
--help, -h show help (default: false)
```## Usage example
```sh
$ ./k8s-diagrams -n mynamespace -d diagrams -o k8s
$ cd diagrams
$ dot -Tpng k8s.dot > k8s.png
```## Render example
### Small namespace

### Big namespace
