The following demo assumes a running minikube instance.
First grab access to the Docker socket for minikube. On *nix:
eval $(minikube docker-env)
On Windows:
& minikube docker-env | Invoke-Expression
Now lets demonstrate running lumogon:
docker run --rm -v /var/run/docker.sock:/var/run/docker.sock puppet/lumogon scan
For the demo you'll want to install a few python packages.
pip install kubernetes docker
We'll also want some seed data.
kubectl apply -f app1.yaml
kubectl apply -f app2.yaml
kubectl apply -f app3.yaml
Then lets run the first of our scripts, which should output to stdout:
collect_data_from_api_and_lumogon.py
Finally pipe that output into the second script which provides the nice UI for the data.
collect_data_from_api_and_lumogon.py | output_package_table.py
On windows you might run into an encoding issue, eg. LookupError: unknown encoding: cp65001
.
You can avoid this with set PYTHONIOENCODING=UTF-8
or $Env:PYTHONIOENCODING="UTF-8"
if you're
using PowerShell.