Skip to main content
Hand-authored illustration. The YAML on this page illustrates the shape of the policies kguardian generates for this workload — it is not captured generator output. Exact metadata, rule grouping, and selectors produced by kubectl kguardian gen will differ. Regeneration of this gallery from a live cluster is planned.

Workload

A prom/prometheus:v2.54.1 deployment in the monitoring namespace. It scrapes a fan-out of metrics endpoints across the cluster (kubelets, kube-state-metrics, app pods, CoreDNS), accepts UI traffic from a Grafana sidecar, and queries the Kubernetes API for service-discovery.

Generated NetworkPolicy

Generated CiliumNetworkPolicy

Generated seccomp profile (excerpt)

Full profile contains 131 syscall names. Representative excerpt:

What kguardian observed

Prometheus’s egress is the most interesting piece: scrape requests fan out to every namespace on a small, well-known set of metrics ports (8080, 9100, 9153, 10250). The single namespaceSelector: {} egress rule shown above is a hand-idealization — the generator emits one rule per observed peer, with pod and namespace selectors for in-cluster targets. Ingress was a single source — Grafana — querying the Prometheus API on TCP/9090. Egress to the Kubernetes API service ClusterIP was captured for service-discovery LIST/WATCH calls. The syscall profile picks up pwrite64/fdatasync because Prometheus persists samples to disk via its WAL.