INNER CODE UNIT · Python
VolumesKPI
DataDog/KubeHound · scripts/dashboard-demo/main.py:142
class VolumesKPI(KPI):
DISPLAY_TITLE = "Volumes"
KH_QUERY_MIN_HOPS = "kh.volumes().minHopsToCritical()"
KH_QUERY_EXTERNAL_COUNTS = "kh.volumes().count()"
KH_QUERY_DETAILS= 'kh.volumes().criticalPaths().limit(local,1).dedup().valueMap("name","sourcePath", "namespace")'
KH_QUERY_DETAILS_KEYS = ["name", "sourcePath"]
KH_QUERY_EXTERNAL_CRITICAL_PATH = '''kh.V().
has("class","Volume").
count().
aggregate("t").
V().
has("class","Volume").
hasCriticalPath().
count().
as("e").
math("100 * e/t").by().by(unfold())'''
DESCRIPTION = '''
### Volumes issues