rate(container_cpu_usage_seconds[10m])/(container_spec_cpu_quota / container_spec_cpu_period)
by Pod and Container
sum(rate(container_cpu_usage_seconds_total{name!~".*prometheus.*", image!="", container!="POD"}[5m])) by (pod, container)
/
sum(container_spec_cpu_quota{name!~".*prometheus.*",image!="",container!="POD"}/container_spec_cpu_period{name!~".*prometheus.*", image!="", container!="POD"}) by (pod, container) * 100
avg/max CPU usage of a set of Pods behind a App?
avg by(container) (rate(container_cpu_usage_seconds_total{container="myapp",metrics_path="/metrics/cadvisor",namespace="defualt"}[5m])
/
ignoring(cpu)
(container_spec_cpu_quota{container="myapp",metrics_path="/metrics/cadvisor",namespace="default"}/container_spec_cpu_period{container="myapp",metrics_path="/metrics/cadvisor",namespace="default"})*100)
avg/max MEM usage of a set of Pods behind a App?
avg by (container_name) (container_memory_rss{namespace="default",container_name="{{$values.app}}",metrics_path="/metrics/cadvisor"}
/
container_spec_memory_limit_bytes{namespace="default",container_name="{{$values.app}}",metrics_path="/metrics/cadvisor"}
cAdvisor metric doc