Commit 89fb3032 by Frank Mai Committed by Alena Prokharchyk

Copy from v0.0.2

parent 65c9bba1
# Patterns to ignore when building packages.
# This supports shell glob matching, relative path matching, and
# negation (prefixed with !). Only one pattern per line.
.DS_Store
# Common VCS dirs
.git/
.gitignore
.bzr/
.bzrignore
.hg/
.hgignore
.svn/
# Common backup files
*.swp
*.bak
*.tmp
*~
# Various IDEs
.project
.idea/
*.tmproj
apiVersion: v1
description: Provides monitoring for Kubernetes which maintaining by Rancher 2.
engine: gotpl
maintainers:
- name: thxCode
email: frank@rancher.com
name: rancher-monitoring
sources:
- https://github.com/coreos/prometheus-operator
version: 0.0.2
appVersion: 0.0.2
home: https://github.com/coreos/prometheus-operator
keywords:
- operator
- prometheus
icon: https://coreos.com/sites/default/files/inline-images/Overview-prometheus_0.png
# rancher-monitoring
Installs [prometheus-operator](https://github.com/coreos/prometheus-operator) to create/configure/manage Prometheus clusters atop Kubernetes.
> **Tip**: Only use for Rancher Monitoring!!!
## Prerequisites
- Rancher 2.2+
apiVersion: v1
description: Creates Alertmanager CRD instance for Kubernetes which maintaining by Rancher 2.
engine: gotpl
maintainers:
- name: thxCode
email: frank@rancher.com
name: alertmanager
version: 0.0.1
apiVersion: {{ template "operator_api_version" . }}
kind: Alertmanager
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ .Release.Name }}
spec:
{{- if .Values.securityContext }}
securityContext:
{{ toYaml .Values.securityContext | indent 4 }}
{{- end }}
podMetadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
baseImage: {{ template "system_default_registry" . }}{{ .Values.image.repository }}
nodeSelector:
beta.kubernetes.io/os: linux
{{- range .Values.nodeSelectors }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
paused: {{ .Values.paused }}
replicas: {{ .Values.replicaCount }}
logLevel: {{ .Values.logLevel }}
{{- if and .Values.resources .Values.resources.core }}
resources:
{{ toYaml .Values.resources.core | indent 4 }}
{{- end }}
retention: "{{ .Values.retention }}"
{{- if .Values.secrets }}
secrets:
{{ toYaml .Values.secrets | indent 4 }}
{{- end }}
{{- if .Values.enabledRBAC }}
serviceAccountName: {{ default (include "app.fullname" .) .Values.serviceAccountName }}
{{- end }}
{{- if or .Values.storageSpec .Values.persistence.enabled }}
storage:
volumeClaimTemplate:
spec:
{{- if .Values.storageSpec }}
{{ toYaml .Values.storageSpec | indent 8 }}
{{- else }}
{{ if and .Values.persistence.storageClass (ne "default" .Values.persistence.storageClass) }}
storageClassName: {{ .Values.persistence.storageClass }}
{{ end }}
accessModes:
- {{ default "ReadWriteOnce" .Values.persistence.accessMode }}
resources:
requests:
storage: {{ .Values.persistence.size | quote }}
{{- end }}
{{- end }}
version: "{{ .Values.image.tag }}"
affinity:
podAntiAffinity:
preferredDuringSchedulingIgnoredDuringExecution:
- weight: 100
podAffinityTerm:
topologyKey: kubernetes.io/hostname
labelSelector:
matchLabels:
app: {{ template "app.name" . }}
alertmanager: {{ .Release.Name }}
{{- if .Values.tolerations }}
tolerations:
{{ toYaml .Values.tolerations | indent 4 }}
{{- end }}
apiVersion: v1
kind: Service
metadata:
name: expose-alertmanager-metrics
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
{{ .Values.apiGroup }}: "true"
spec:
type: ClusterIP
clusterIP: None
selector:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
ports:
- name: http
port: 9093
targetPort: web
\ No newline at end of file
{{- if and .Values.enabledRBAC (not .Values.serviceAccountName) }}
apiVersion: v1
kind: ServiceAccount
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ template "app.fullname" . }}
imagePullSecrets:
{{ toYaml .Values.image.pullSecrets | indent 2 }}
{{- end }}
\ No newline at end of file
{{- if not .Values.configFromSecret }}
apiVersion: v1
kind: Secret
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ template "app.fullname" . }}
data:
alertmanager.yaml: {{ toYaml .Values.config | b64enc | quote }}
{{- range $key, $val := .Values.templates }}
{{ $key }}: {{ $val | b64enc | quote }}
{{- end }}
{{- end }}
apiVersion: v1
kind: Service
metadata:
name: access-alertmanager
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
kubernetes.io/cluster-service: "true"
spec:
type: ClusterIP
selector:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
ports:
- name: http
port: 80
targetPort: web
apiVersion: {{ template "operator_api_version" . }}
kind: ServiceMonitor
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
source: rancher-monitoring
name: {{ template "app.fullname" . }}
spec:
selector:
matchLabels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
{{ .Values.apiGroup }}: "true"
namespaceSelector:
matchNames:
- {{ .Release.Namespace | quote }}
endpoints:
- port: http
interval: 30s
relabelings:
- sourceLabels:
- __meta_kubernetes_pod_host_ip
targetLabel: host_ip
action: replace
regex: (.+)
replacement: $1
- sourceLabels:
- __meta_kubernetes_pod_node_name
targetLabel: node
action: replace
regex: (.+)
replacement: $1
enabledRBAC: true
## The name of a secret in the same kubernetes namespace which contains the Alertmanager config
## If defined this will be used instead of the `config` block values.
## The name of the secret must be alertmanager-{{ .Release.Name }} and its data must contain, at least, a key called `alertmanager.yaml`
## that contains the configuration as value.
##
configFromSecret: ""
## Alertmanager template files to include
#
templates: {}
#
# An example template:
# template_1.tmpl: |-
# {{ define "cluster" }}{{ .ExternalURL | reReplaceAll ".*alertmanager\\.(.*)" "$1" }}{{ end }}
#
# {{ define "slack.myorg.text" }}
# {{- $root := . -}}
# {{ range .Alerts }}
# *Alert:* {{ .Annotations.summary }} - `{{ .Labels.severity }}`
# *Cluster:* {{ template "cluster" $root }}
# *Description:* {{ .Annotations.description }}
# *Graph:* <{{ .GeneratorURL }}|:chart_with_upwards_trend:>
# *Runbook:* <{{ .Annotations.runbook }}|:spiral_note_pad:>
# *Details:*
# {{ range .Labels.SortedPairs }} • *{{ .Name }}:* `{{ .Value }}`
# {{ end }}
## Tolerations for use with node taints
## Ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/
##
tolerations: []
# - key: "key"
# operator: "Equal"
# value: "value"
# effect: "NoSchedule"
## If true, the Operator won't process any Alertmanager configuration changes
##
paused: false
## Number of Alertmanager replicas desired
##
replicaCount: 1
## How long to retain metrics
##
retention: 24h
## List of Secrets in the same namespace as the Alertmanager
## object, which shall be mounted into the Alertmanager Pods.
## Ref: https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#prometheusspec
##
secrets: []
logLevel: "info"
## Alertmanager StorageSpec for persistent data
## Ref: https://github.com/coreos/prometheus-operator/blob/master/Documentation/user-guides/storage.md
##
storageSpec: {}
# storageClassName: gluster
# accessModes: ["ReadWriteOnce"]
# resources:
# requests:
# storage: 50Gi
# selector: {}
apiVersion: v1
description: Creates ServiceMonitor CRD of coredns for Kubernetes which maintaining by Rancher 2.
engine: gotpl
maintainers:
- name: thxCode
email: frank@rancher.com
name: exporter-coredns
version: 0.0.1
{{- if .Values.endpoints }}
apiVersion: v1
kind: Endpoints
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: expose-coredns-metrics
subsets:
- addresses:
{{- range .Values.endpoints }}
- ip: {{ . }}
{{- end }}
ports:
- name: {{ .Values.ports.metrics.name }}
port: {{ .Values.ports.metrics.port }}
protocol: {{ .Values.ports.metrics.protocol }}
{{- end }}
apiVersion: v1
kind: Service
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
{{- range .Values.serviceSelectorLabels }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
name: expose-coredns-metrics
namespace: {{ .Release.Namespace }}
spec:
type: ClusterIP
clusterIP: None
ports:
- name: {{ .Values.ports.metrics.name }}
port: {{ .Values.ports.metrics.port }}
protocol: {{ .Values.ports.metrics.protocol }}
targetPort: {{ .Values.ports.metrics.port }}
{{- if not .Values.endpoints }}
selector:
{{- range .Values.serviceSelectorLabels }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
{{- end }}
\ No newline at end of file
apiVersion: {{ template "operator_api_version" . }}
kind: ServiceMonitor
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
source: rancher-monitoring
name: {{ template "app.fullname" . }}
spec:
selector:
matchLabels:
{{- range .Values.serviceSelectorLabels }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
namespaceSelector:
matchNames:
{{- if not .Values.endpoints }}
- "kube-system"
{{- else }}
- {{ .Release.Namespace | quote }}
{{- end }}
endpoints:
- port: {{ .Values.ports.metrics.name }}
interval: 15s
bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
scheme: {{ .Values.ports.metrics.scheme }}
{{- if eq .Values.ports.metrics.scheme "https" }}
tlsConfig:
caFile: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt
{{- if .Values.insecureSkipVerify }}
insecureSkipVerify: true
{{- end }}
{{- end }}
relabelings:
- sourceLabels:
- __meta_kubernetes_pod_host_ip
targetLabel: host_ip
action: replace
regex: (.+)
replacement: $1
- sourceLabels:
- __meta_kubernetes_pod_node_name
targetLabel: node
action: replace
regex: (.+)
replacement: $1
apiVersion: v1
description: Creates Fluentd Metrics Exporter instance for Kubernetes which maintaining by Rancher 2.
engine: gotpl
maintainers:
- name: aiwantaozi
email: michelia.feng@gmail.com
name: exporter-fluentd
version: 0.0.1
apiVersion: {{ template "operator_api_version" . }}
kind: ServiceMonitor
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
source: rancher-monitoring
name: {{ template "app.fullname" . }}
spec:
selector:
matchLabels:
{{- range .Values.serviceSelectorLabels }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
namespaceSelector:
matchNames:
- cattle-logging
endpoints:
- port: {{ .Values.ports.metrics.name }}
interval: 15s
honorLabels: true
bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
scheme: {{ .Values.ports.metrics.scheme }}
{{- if eq .Values.ports.metrics.scheme "https" }}
tlsConfig:
caFile: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt
{{- if .Values.insecureSkipVerify }}
insecureSkipVerify: true
{{- end }}
{{- end }}
relabelings:
- sourceLabels:
- __meta_kubernetes_pod_host_ip
targetLabel: host_ip
action: replace
regex: (.+)
replacement: $1
- sourceLabels:
- __meta_kubernetes_pod_node_name
targetLabel: node
action: replace
regex: (.+)
replacement: $1
apiVersion: v1
description: Creates ServiceMonitor CRD of controller manager for Kubernetes which maintaining by Rancher 2.
engine: gotpl
maintainers:
- name: thxCode
email: frank@rancher.com
name: exporter-kube-controller-manager
version: 0.0.1
{{- if .Values.endpoints }}
apiVersion: v1
kind: Endpoints
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: expose-kube-cm-metrics
subsets:
- addresses:
{{- range .Values.endpoints }}
- ip: {{ . }}
{{- end }}
ports:
- name: {{ .Values.ports.metrics.name }}
port: {{ .Values.ports.metrics.port }}
protocol: {{ .Values.ports.metrics.protocol }}
{{- end }}
apiVersion: v1
kind: Service
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
{{- range .Values.serviceSelectorLabels }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
name: expose-kube-cm-metrics
namespace: {{ .Release.Namespace }}
spec:
type: ClusterIP
clusterIP: None
ports:
- name: {{ .Values.ports.metrics.name }}
port: {{ .Values.ports.metrics.port }}
protocol: {{ .Values.ports.metrics.protocol }}
targetPort: {{ .Values.ports.metrics.port }}
{{- if not .Values.endpoints }}
selector:
{{- range .Values.serviceSelectorLabels }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
{{- end }}
apiVersion: {{ template "operator_api_version" . }}
kind: ServiceMonitor
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
source: rancher-monitoring
name: {{ template "app.fullname" . }}
spec:
selector:
matchLabels:
{{- range .Values.serviceSelectorLabels }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
namespaceSelector:
matchNames:
{{- if not .Values.endpoints }}
- "kube-system"
{{- else }}
- {{ .Release.Namespace | quote }}
{{- end }}
endpoints:
- port: {{ .Values.ports.metrics.name }}
interval: 15s
bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
scheme: {{ .Values.ports.metrics.scheme }}
{{- if eq .Values.ports.metrics.scheme "https" }}
tlsConfig:
caFile: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt
{{- if .Values.insecureSkipVerify }}
insecureSkipVerify: true
{{- end }}
{{- end }}
relabelings:
- sourceLabels:
- __meta_kubernetes_pod_host_ip
targetLabel: host_ip
action: replace
regex: (.+)
replacement: $1
- sourceLabels:
- __meta_kubernetes_pod_node_name
targetLabel: node
action: replace
regex: (.+)
replacement: $1
apiVersion: v1
description: Creates ServiceMonitor CRD of kube-dns for Kubernetes which maintaining by Rancher 2.
engine: gotpl
maintainers:
- name: thxCode
email: frank@rancher.com
name: exporter-kube-dns
version: 0.0.1
{{- if .Values.endpoints }}
apiVersion: v1
kind: Endpoints
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: expose-kube-dns-metrics
subsets:
- addresses:
{{- range .Values.endpoints }}
- ip: {{ . }}
{{- end }}
ports:
- name: {{ .Values.ports.metrics.dnsmasq.name }}
port: {{ .Values.ports.metrics.dnsmasq.port }}
protocol: {{ .Values.ports.metrics.dnsmasq.protocol }}
- name: {{ .Values.ports.metrics.skydns.name }}
port: {{ .Values.ports.metrics.skydns.port }}
protocol: {{ .Values.ports.metrics.skydns.protocol }}
{{- end }}
apiVersion: v1
kind: Service
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
{{- range .Values.serviceSelectorLabels }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
name: expose-kube-dns-metrics
namespace: {{ .Release.Namespace }}
spec:
type: ClusterIP
clusterIP: None
ports:
- name: {{ .Values.ports.metrics.dnsmasq.name }}
port: {{ .Values.ports.metrics.dnsmasq.port }}
protocol: {{ .Values.ports.metrics.dnsmasq.protocol }}
targetPort: {{ .Values.ports.metrics.dnsmasq.port }}
- name: {{ .Values.ports.metrics.skydns.name }}
port: {{ .Values.ports.metrics.skydns.port }}
protocol: {{ .Values.ports.metrics.skydns.protocol }}
targetPort: {{ .Values.ports.metrics.skydns.port }}
{{- if not .Values.endpoints }}
selector:
{{- range .Values.serviceSelectorLabels }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
{{- end }}
\ No newline at end of file
apiVersion: {{ template "operator_api_version" . }}
kind: ServiceMonitor
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
source: rancher-monitoring
name: {{ template "app.fullname" . }}
spec:
selector:
matchLabels:
{{- range .Values.serviceSelectorLabels }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
namespaceSelector:
matchNames:
{{- if not .Values.endpoints }}
- "kube-system"
{{- else }}
- {{ .Release.Namespace | quote }}
{{- end }}
endpoints:
- port: {{ .Values.ports.metrics.dnsmasq.name }}
interval: 15s
bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
scheme: {{ .Values.ports.metrics.dnsmasq.scheme }}
{{- if eq .Values.ports.metrics.dnsmasq.scheme "https" }}
tlsConfig:
caFile: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt
{{- if .Values.insecureSkipVerify }}
insecureSkipVerify: true
{{- end }}
{{- end }}
relabelings:
- sourceLabels:
- __meta_kubernetes_pod_host_ip
targetLabel: host_ip
action: replace
regex: (.+)
replacement: $1
- sourceLabels:
- __meta_kubernetes_pod_node_name
targetLabel: node
action: replace
regex: (.+)
replacement: $1
- port: {{ .Values.ports.metrics.skydns.name }}
interval: 15s
bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
scheme: {{ .Values.ports.metrics.skydns.scheme }}
{{- if eq .Values.ports.metrics.skydns.scheme "https" }}
tlsConfig:
caFile: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt
{{- if .Values.insecureSkipVerify }}
insecureSkipVerify: true
{{- end }}
{{- end }}
relabelings:
- sourceLabels:
- __meta_kubernetes_pod_host_ip
targetLabel: host_ip
action: replace
regex: (.+)
replacement: $1
- sourceLabels:
- __meta_kubernetes_pod_node_name
targetLabel: node
action: replace
regex: (.+)
replacement: $1
apiVersion: v1
description: Creates ServiceMonitor CRD of etcd for Kubernetes which maintaining by Rancher 2.
engine: gotpl
maintainers:
- name: thxCode
email: frank@rancher.com
name: exporter-kube-etcd
version: 0.0.1
{{- if .Values.endpoints }}
apiVersion: v1
kind: Endpoints
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: expose-kube-etcd-metrics
subsets:
- addresses:
{{- range .Values.endpoints }}
- ip: {{ . }}
{{- end }}
ports:
- name: {{ .Values.ports.metrics.name }}
port: {{ .Values.ports.metrics.port }}
protocol: {{ .Values.ports.metrics.protocol }}
{{- end }}
apiVersion: v1
kind: Service
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
{{- range .Values.serviceSelectorLabels }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
name: expose-kube-etcd-metrics
namespace: {{ .Release.Namespace }}
spec:
type: ClusterIP
clusterIP: None
ports:
- name: {{ .Values.ports.metrics.name }}
port: {{ .Values.ports.metrics.port }}
protocol: {{ .Values.ports.metrics.protocol }}
targetPort: {{ .Values.ports.metrics.port }}
{{- if not .Values.endpoints }}
selector:
{{- range .Values.serviceSelectorLabels }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
{{- end }}
\ No newline at end of file
apiVersion: {{ template "operator_api_version" . }}
kind: ServiceMonitor
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
source: rancher-monitoring
name: {{ template "app.fullname" . }}
spec:
selector:
matchLabels:
{{- range .Values.serviceSelectorLabels }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
namespaceSelector:
matchNames:
{{- if not .Values.endpoints }}
- "kube-system"
{{- else }}
- {{ .Release.Namespace | quote }}
{{- end }}
endpoints:
- port: {{ .Values.ports.metrics.name }}
interval: 15s
bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
scheme: {{ .Values.ports.metrics.scheme }}
{{- if eq .Values.ports.metrics.scheme "https" }}
tlsConfig:
caFile: {{ .Values.caFile }}
{{- if .Values.certFile }}
certFile: {{ .Values.certFile }}
{{- end }}
{{- if .Values.keyFile }}
keyFile: {{ .Values.keyFile }}
{{- end}}
{{- if .Values.insecureSkipVerify }}
insecureSkipVerify: true
{{- end }}
{{- end }}
relabelings:
- sourceLabels:
- __meta_kubernetes_pod_host_ip
targetLabel: host_ip
action: replace
regex: (.+)
replacement: $1
- sourceLabels:
- __meta_kubernetes_pod_node_name
targetLabel: node
action: replace
regex: (.+)
replacement: $1
apiVersion: v1
description: Creates ServiceMonitor CRD of scheduler for Kubernetes which maintaining by Rancher 2.
engine: gotpl
maintainers:
- name: thxCode
email: frank@rancher.com
name: exporter-kube-scheduler
version: 0.0.1
{{- if .Values.endpoints }}
apiVersion: v1
kind: Endpoints
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: expose-kube-scheduler-metrics
subsets:
- addresses:
{{- range .Values.endpoints }}
- ip: {{ . }}
{{- end }}
ports:
- name: {{ .Values.ports.metrics.name }}
port: {{ .Values.ports.metrics.port }}
protocol: {{ .Values.ports.metrics.protocol }}
{{- end }}
\ No newline at end of file
apiVersion: {{ template "operator_api_version" . }}
kind: PrometheusRule
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
source: rancher-monitoring
name: {{ template "app.fullname" . }}
spec:
groups:
- name: kube-scheduler.rules
rules:
- record: cluster:scheduler_e2e_scheduling_latency_seconds:quantile
expr: histogram_quantile(0.99, sum(scheduler_e2e_scheduling_latency_microseconds_bucket)
BY (le, cluster)) / 1e+06
labels:
quantile: "0.99"
- record: cluster:scheduler_e2e_scheduling_latency_seconds:quantile
expr: histogram_quantile(0.9, sum(scheduler_e2e_scheduling_latency_microseconds_bucket)
BY (le, cluster)) / 1e+06
labels:
quantile: "0.9"
- record: cluster:scheduler_e2e_scheduling_latency_seconds:quantile
expr: histogram_quantile(0.5, sum(scheduler_e2e_scheduling_latency_microseconds_bucket)
BY (le, cluster)) / 1e+06
labels:
quantile: "0.5"
- record: cluster:scheduler_scheduling_algorithm_latency_seconds:quantile
expr: histogram_quantile(0.99, sum(scheduler_scheduling_algorithm_latency_microseconds_bucket)
BY (le, cluster)) / 1e+06
labels:
quantile: "0.99"
- record: cluster:scheduler_scheduling_algorithm_latency_seconds:quantile
expr: histogram_quantile(0.9, sum(scheduler_scheduling_algorithm_latency_microseconds_bucket)
BY (le, cluster)) / 1e+06
labels:
quantile: "0.9"
- record: cluster:scheduler_scheduling_algorithm_latency_seconds:quantile
expr: histogram_quantile(0.5, sum(scheduler_scheduling_algorithm_latency_microseconds_bucket)
BY (le, cluster)) / 1e+06
labels:
quantile: "0.5"
- record: cluster:scheduler_binding_latency_seconds:quantile
expr: histogram_quantile(0.99, sum(scheduler_binding_latency_microseconds_bucket)
BY (le, cluster)) / 1e+06
labels:
quantile: "0.99"
- record: cluster:scheduler_binding_latency_seconds:quantile
expr: histogram_quantile(0.9, sum(scheduler_binding_latency_microseconds_bucket)
BY (le, cluster)) / 1e+06
labels:
quantile: "0.9"
- record: cluster:scheduler_binding_latency_seconds:quantile
expr: histogram_quantile(0.5, sum(scheduler_binding_latency_microseconds_bucket)
BY (le, cluster)) / 1e+06
labels:
quantile: "0.5"
\ No newline at end of file
apiVersion: v1
kind: Service
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
{{- range .Values.serviceSelectorLabels }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
name: expose-kube-scheduler-metrics
namespace: {{ .Release.Namespace }}
spec:
type: ClusterIP
clusterIP: None
ports:
- name: {{ .Values.ports.metrics.name }}
port: {{ .Values.ports.metrics.port }}
protocol: {{ .Values.ports.metrics.protocol }}
targetPort: {{ .Values.ports.metrics.port }}
{{- if not .Values.endpoints }}
selector:
{{- range .Values.serviceSelectorLabels }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
{{- end }}
apiVersion: {{ template "operator_api_version" . }}
kind: ServiceMonitor
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
source: rancher-monitoring
name: {{ template "app.fullname" . }}
spec:
selector:
matchLabels:
{{- range .Values.serviceSelectorLabels }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
namespaceSelector:
matchNames:
{{- if not .Values.endpoints }}
- "kube-system"
{{- else }}
- {{ .Release.Namespace | quote }}
{{- end }}
endpoints:
- port: {{ .Values.ports.metrics.name }}
interval: 15s
bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
scheme: {{ .Values.ports.metrics.scheme }}
{{- if eq .Values.ports.metrics.scheme "https" }}
tlsConfig:
caFile: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt
{{- if .Values.insecureSkipVerify }}
insecureSkipVerify: true
{{- end }}
{{- end }}
relabelings:
- sourceLabels:
- __meta_kubernetes_pod_host_ip
targetLabel: host_ip
action: replace
regex: (.+)
replacement: $1
- sourceLabels:
- __meta_kubernetes_pod_node_name
targetLabel: node
action: replace
regex: (.+)
replacement: $1
apiVersion: v1
description: Creates Kube-state Exporter instance for Kubernetes which maintaining by Rancher 2.
engine: gotpl
maintainers:
- name: thxCode
email: frank@rancher.com
name: exporter-kube-state
version: 0.0.1
apiVersion: {{ template "deployment_api_version" . }}
kind: Deployment
metadata:
name: {{ template "app.fullname" . }}
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
spec:
replicas: {{ .Values.replicaCount }}
selector:
matchLabels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
template:
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
spec:
containers:
- name: kube-state
image: {{ template "system_default_registry" . }}{{ .Values.image.repository }}:{{ .Values.image.tag }}
ports:
- name: http
containerPort: 8080
- name: http-metrics
containerPort: 8081
livenessProbe:
httpGet:
path: /
port: 8080
initialDelaySeconds: 30
timeoutSeconds: 30
readinessProbe:
httpGet:
path: /
port: 8080
initialDelaySeconds: 30
timeoutSeconds: 5
resources:
{{ toYaml .Values.resources | indent 10 }}
{{- if .Values.enabledRBAC }}
serviceAccountName: {{ default (include "app.fullname" .) .Values.serviceAccountName }}
{{- end }}
{{- if .Values.securityContext }}
securityContext:
{{ toYaml .Values.securityContext | indent 8 }}
{{- end }}
{{- if .Values.tolerations }}
tolerations:
{{ toYaml .Values.tolerations | indent 8 }}
{{- end }}
nodeSelector:
beta.kubernetes.io/os: linux
{{- range .Values.nodeSelectors }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
{{- if and .Values.enabledRBAC (not .Values.serviceAccountName) }}
apiVersion: {{ template "rbac_api_version" . }}
kind: ClusterRole
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ template "app.fullname" . }}
rules:
- apiGroups:
- ""
resources:
- namespaces
- nodes
- pods
- services
- resourcequotas
- replicationcontrollers
- limitranges
- persistentvolumeclaims
- persistentvolumes
- endpoints
- configmaps
- secrets
verbs:
- "list"
- "watch"
- apiGroups:
- "extensions"
resources:
- daemonsets
- deployments
- replicasets
verbs:
- "list"
- "watch"
- apiGroups:
- "apps"
resources:
- statefulsets
- deployments
verbs:
- "list"
- "watch"
- apiGroups:
- "batch"
resources:
- cronjobs
- jobs
verbs:
- "list"
- "watch"
- apiGroups:
- "autoscaling"
resources:
- horizontalpodautoscalers
verbs:
- "list"
- "watch"
---
apiVersion: v1
kind: ServiceAccount
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ template "app.fullname" . }}
imagePullSecrets:
{{ toYaml .Values.image.pullSecrets | indent 2 }}
---
apiVersion: {{ template "rbac_api_version" . }}
kind: ClusterRoleBinding
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ template "app.fullname" . }}
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
name: {{ template "app.fullname" . }}
subjects:
- kind: ServiceAccount
name: {{ template "app.fullname" . }}
namespace: {{ .Release.Namespace }}
{{- end }}
apiVersion: v1
kind: Service
metadata:
name: expose-kubernetes-metrics
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
k8s-app: kube-state
{{ .Values.apiGroup }}: "true"
spec:
type: ClusterIP
clusterIP: None
selector:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
ports:
- name: http
port: 8080
targetPort: http
- name: http-metrics
port: 8081
targetPort: http-metrics
apiVersion: {{ template "operator_api_version" . }}
kind: ServiceMonitor
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
source: rancher-monitoring
name: {{ template "app.fullname" . }}
spec:
selector:
matchLabels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
{{ .Values.apiGroup }}: "true"
namespaceSelector:
matchNames:
- {{ .Release.Namespace | quote }}
endpoints:
- port: http
interval: 15s
honorLabels: true
relabelings:
- sourceLabels:
- __meta_kubernetes_pod_host_ip
targetLabel: host_ip
action: replace
regex: (.+)
replacement: $1
- sourceLabels:
- __meta_kubernetes_pod_node_name
targetLabel: node
action: replace
regex: (.+)
replacement: $1
- port: http-metrics
interval: 30s
relabelings:
- sourceLabels:
- __meta_kubernetes_pod_host_ip
targetLabel: host_ip
action: replace
regex: (.+)
replacement: $1
- sourceLabels:
- __meta_kubernetes_pod_node_name
targetLabel: node
action: replace
regex: (.+)
replacement: $1
enabledRBAC: true
## Tolerations for use with node taints
## Ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/
##
tolerations: []
# - key: "key"
# operator: "Equal"
# value: "value"
# effect: "NoSchedule"
apiVersion: v1
description: Creates ServiceMonitor CRD of kublets for Kubernetes which maintaining by Rancher 2.
engine: gotpl
maintainers:
- name: thxCode
email: frank@rancher.com
name: exporter-kubelets
version: 0.0.1
apiVersion: {{ template "operator_api_version" . }}
kind: ServiceMonitor
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
source: rancher-monitoring
name: {{ template "charts.exporter-kubelets.fullname" . }}
spec:
selector:
matchLabels:
{{- range .Values.serviceSelectorLabels }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
namespaceSelector:
matchNames:
- {{ .Release.Namespace | quote }}
endpoints:
{{- if .Values.https }}
- port: https-metrics
scheme: https
interval: 15s
bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
tlsConfig:
caFile: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt
{{- if .Values.insecureSkipVerify }}
insecureSkipVerify: true
{{- end }}
relabelings:
- sourceLabels:
- __meta_kubernetes_pod_host_ip
targetLabel: host_ip
action: replace
regex: (.+)
replacement: $1
- sourceLabels:
- __meta_kubernetes_pod_node_name
targetLabel: node
action: replace
regex: (.+)
replacement: $1
- port: https-metrics
scheme: https
path: /metrics/cadvisor
interval: 30s
honorLabels: true
bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
tlsConfig:
caFile: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt
{{- if .Values.insecureSkipVerify }}
insecureSkipVerify: true
{{- end }}
relabelings:
- sourceLabels:
- __meta_kubernetes_pod_host_ip
targetLabel: host_ip
action: replace
regex: (.+)
replacement: $1
- sourceLabels:
- __meta_kubernetes_pod_node_name
targetLabel: node
action: replace
regex: (.+)
replacement: $1
{{- else }}
- port: http-metrics
interval: 15s
relabelings:
- sourceLabels:
- __meta_kubernetes_pod_host_ip
targetLabel: host_ip
action: replace
regex: (.+)
replacement: $1
- sourceLabels:
- __meta_kubernetes_pod_node_name
targetLabel: node
action: replace
regex: (.+)
replacement: $1
- port: http-metrics
path: /metrics/cadvisor
interval: 30s
honorLabels: true
relabelings:
- sourceLabels:
- __meta_kubernetes_pod_host_ip
targetLabel: host_ip
action: replace
regex: (.+)
replacement: $1
- sourceLabels:
- __meta_kubernetes_pod_node_name
targetLabel: node
action: replace
regex: (.+)
replacement: $1
{{- end }}
apiVersion: v1
description: Creates ServiceMonitor CRD of apiserver for Kubernetes which maintaining by Rancher 2.
engine: gotpl
maintainers:
- name: thxCode
email: frank@rancher.com
name: exporter-kubernetes
version: 0.0.1
apiVersion: {{ template "operator_api_version" . }}
kind: PrometheusRule
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
source: rancher-monitoring
name: {{ template "app.fullname" . }}
spec:
groups:
- name: kubernetes.rules
rules:
- record: pod_name:container_memory_usage_bytes:sum
expr: sum(container_memory_usage_bytes{container_name!="POD",pod_name!=""}) BY
(pod_name)
- record: pod_name:container_spec_cpu_shares:sum
expr: sum(container_spec_cpu_shares{container_name!="POD",pod_name!=""}) BY (pod_name)
- record: pod_name:container_cpu_usage:sum
expr: sum(rate(container_cpu_usage_seconds_total{container_name!="POD",pod_name!=""}[5m]))
BY (pod_name)
- record: pod_name:container_fs_usage_bytes:sum
expr: sum(container_fs_usage_bytes{container_name!="POD",pod_name!=""}) BY (pod_name)
- record: namespace:container_memory_usage_bytes:sum
expr: sum(container_memory_usage_bytes{container_name!=""}) BY (namespace)
- record: namespace:container_spec_cpu_shares:sum
expr: sum(container_spec_cpu_shares{container_name!=""}) BY (namespace)
- record: namespace:container_cpu_usage:sum
expr: sum(rate(container_cpu_usage_seconds_total{container_name!="POD"}[5m]))
BY (namespace)
- record: cluster:memory_usage:ratio
expr: sum(container_memory_usage_bytes{container_name!="POD",pod_name!=""}) BY
(cluster) / sum(machine_memory_bytes) BY (cluster)
- record: cluster:container_spec_cpu_shares:ratio
expr: sum(container_spec_cpu_shares{container_name!="POD",pod_name!=""}) / 1000
/ sum(machine_cpu_cores)
- record: cluster:container_cpu_usage:ratio
expr: sum(rate(container_cpu_usage_seconds_total{container_name!="POD",pod_name!=""}[5m]))
/ sum(machine_cpu_cores)
- record: apiserver_latency_seconds:quantile
expr: histogram_quantile(0.99, rate(apiserver_request_latencies_bucket[5m])) /
1e+06
labels:
quantile: "0.99"
- record: apiserver_latency:quantile_seconds
expr: histogram_quantile(0.9, rate(apiserver_request_latencies_bucket[5m])) /
1e+06
labels:
quantile: "0.9"
- record: apiserver_latency_seconds:quantile
expr: histogram_quantile(0.5, rate(apiserver_request_latencies_bucket[5m])) /
1e+06
labels:
quantile: "0.5"
\ No newline at end of file
apiVersion: {{ template "operator_api_version" . }}
kind: ServiceMonitor
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
source: rancher-monitoring
name: {{ template "app.fullname" . }}
spec:
selector:
matchLabels:
{{- range .Values.serviceSelectorLabels }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
namespaceSelector:
matchNames:
- "default"
endpoints:
- port: {{ .Values.ports.metrics.name }}
interval: 15s
bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
scheme: {{ .Values.ports.metrics.scheme }}
{{- if eq .Values.ports.metrics.scheme "https" }}
tlsConfig:
caFile: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt
{{- if .Values.insecureSkipVerify }}
insecureSkipVerify: true
{{- end }}
{{- end }}
relabelings:
- sourceLabels:
- __meta_kubernetes_pod_host_ip
action: replace
targetLabel: host_ip
regex: (.+)
replacement: $1
- sourceLabels:
- __meta_kubernetes_pod_node_name
action: replace
targetLabel: node
regex: (.+)
replacement: $1
apiVersion: v1
description: Creates Node Exporter instance for Kubernetes which maintaining by Rancher 2.
engine: gotpl
maintainers:
- name: thxCode
email: frank@rancher.com
name: exporter-node
version: 0.0.1
\ No newline at end of file
apiVersion: {{ template "daemonset_api_version" . }}
kind: DaemonSet
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ template "app.fullname" . }}
spec:
selector:
matchLabels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
template:
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
spec:
containers:
- name: exporter-node
image: {{ template "system_default_registry" . }}{{ .Values.image.repository }}:{{ .Values.image.tag }}
args:
- --web.listen-address=$(POD_IP):{{ .Values.ports.metrics.port }}
- --path.procfs=/host/proc
- --path.sysfs=/host/sys
- --path.rootfs=/host
{{- $usingCollectors := merge .Values.collectors .Values.defaultCollectorSettings }}
{{- range $collectorName, $collectorVal := $usingCollectors }}
{{- if and $collectorVal $collectorVal.enabled }}
- --collector.{{ $collectorName }}
{{- $_ := unset $collectorVal "enabled" -}}
{{- if $collectorVal }}
{{- range $collectorValKey, $collectorValVal := $collectorVal }}
{{- if $collectorValVal }}
- --collector.{{ $collectorName }}.{{ $collectorValKey }}={{ $collectorValVal }}
{{- else }}
- --collector.{{ $collectorName }}.{{ $collectorValKey }}
{{- end }}
{{- end }}
{{- end }}
{{- else }}
- --no-collector.{{$collectorName}}
{{- end }}
{{- end }}
env:
- name: POD_IP
valueFrom:
fieldRef:
fieldPath: status.podIP
ports:
- name: http
containerPort: {{ .Values.ports.metrics.port }}
{{- if .Values.enabledHostNetwork }}
hostPort: {{ .Values.ports.metrics.port }}
{{- end }}
resources:
{{ toYaml .Values.resources | indent 10 }}
volumeMounts:
- name: proc
mountPath: /host/proc
readOnly: true
- name: sys
mountPath: /host/sys
readOnly: true
- name: host
mountPath: /host
readOnly: true
{{- if .Values.enabledRBAC }}
serviceAccountName: {{ default (include "app.fullname" .) .Values.serviceAccountName }}
{{- end }}
securityContext:
runAsNonRoot: true
runAsUser: 65534
tolerations:
- operator: Exists
nodeSelector:
beta.kubernetes.io/os: linux
{{- range .Values.nodeSelectors }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
{{- if .Values.enabledHostNetwork }}
hostNetwork: true
{{- end }}
{{- if .Values.enabledHostPID }}
hostPID: true
{{- end }}
volumes:
- name: proc
hostPath:
path: /proc
- name: sys
hostPath:
path: /sys
- name: host
hostPath:
path: /
apiVersion: {{ template "operator_api_version" . }}
kind: PrometheusRule
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
source: rancher-monitoring
name: {{ template "app.fullname" . }}
spec:
groups:
- name: node.rules
rules:
- record: instance:node_cpu:rate:sum
expr: sum(rate(node_cpu_seconds_total{mode!="idle",mode!="iowait"}[3m]))
BY (instance)
- record: instance:node_filesystem_usage:sum
expr: sum((node_filesystem_size_bytes{mountpoint="/"} - node_filesystem_free{mountpoint="/"}))
BY (instance)
- record: instance:node_network_receive_bytes:rate:sum
expr: sum(rate(node_network_receive_bytes_total[3m])) BY (instance)
- record: instance:node_network_transmit_bytes:rate:sum
expr: sum(rate(node_network_transmit_bytes_total[3m])) BY (instance)
- record: instance:node_cpu:ratio
expr: sum(rate(node_cpu_seconds_total{mode!="idle",mode!="iowait"}[5m])) WITHOUT (cpu, mode) / ON(instance)
GROUP_LEFT() count(sum(node_cpu_seconds_total) BY (instance, cpu)) BY (instance)
- record: cluster:node_cpu:sum_rate5m
expr: sum(rate(node_cpu_seconds_total{mode!="idle",mode!="iowait"}[5m]))
- record: cluster:node_cpu:ratio
expr: cluster:node_cpu_seconds_total:rate5m / count(sum(node_cpu_seconds_total) BY (instance, cpu))
\ No newline at end of file
{{- if and .Values.enabledRBAC (not .Values.serviceAccountName) }}
apiVersion: {{ template "rbac_api_version" . }}
kind: ClusterRole
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ template "app.fullname" . }}
rules:
- apiGroups:
- authentication.k8s.io
resources:
- tokenreviews
verbs:
- create
- apiGroups:
- authorization.k8s.io
resources:
- subjectaccessreviews
verbs:
- creat
---
apiVersion: v1
kind: ServiceAccount
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ template "app.fullname" . }}
imagePullSecrets:
{{ toYaml .Values.image.pullSecrets | indent 2 }}
---
apiVersion: {{ template "rbac_api_version" . }}
kind: ClusterRoleBinding
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ template "app.fullname" . }}
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
name: {{ template "app.fullname" . }}
subjects:
- kind: ServiceAccount
name: {{ template "app.fullname" . }}
namespace: {{ .Release.Namespace }}
{{- end }}
\ No newline at end of file
apiVersion: v1
kind: Service
metadata:
name: expose-node-metrics
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
k8s-app: node
{{ .Values.apiGroup }}: "true"
spec:
type: ClusterIP
clusterIP: None
selector:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
ports:
- name: metrics
port: {{ .Values.ports.metrics.port }}
targetPort: {{ .Values.ports.metrics.port }}
protocol: TCP
apiVersion: {{ template "operator_api_version" . }}
kind: ServiceMonitor
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
source: rancher-monitoring
name: {{ template "app.fullname" . }}
spec:
selector:
matchLabels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
{{ .Values.apiGroup }}: "true"
namespaceSelector:
matchNames:
- {{ .Release.Namespace | quote }}
endpoints:
- port: metrics
interval: 15s
relabelings:
- sourceLabels:
- __meta_kubernetes_pod_host_ip
targetLabel: host_ip
action: replace
regex: (.+)
replacement: $1
- sourceLabels:
- __meta_kubernetes_pod_node_name
targetLabel: node
action: replace
regex: (.+)
replacement: $1
enabledRBAC: true
##
# Default collector settings
##
defaultCollectorSettings:
##
# Enabled by default on Linux
##
# Exposes ARP statistics from /proc/net/arp
arp:
enabled: true
# Exposes bcache statistics from /sys/fs/bcache/
bcache:
enabled: true
# Exposes the number of configured and active slaves of Linux bonding interfaces
bonding:
enabled: true
# Shows conntrack statistics (does nothing if no /proc/sys/net/netfilter/ present)
conntrack:
enabled: true
# Exposes CPU statistics
cpu:
enabled: true
# Exposes disk I/O statistics.
diskstats:
enabled: true
# Exposes error detection and correction statistics
edac:
enabled: true
# Exposes available entropy
entropy:
enabled: true
# Exposes file descriptor statistics from /proc/sys/fs/file-nr
filefd:
enabled: true
# Exposes filesystem statistics, such as disk space used
filesystem:
enabled: true
# Expose hardware monitoring and sensor data from /sys/class/hwmon/
hwmon:
enabled: true
# Exposes network statistics specific to InfiniBand and Intel OmniPath configurations
infiniband:
enabled: true
# Exposes IPVS status from /proc/net/ip_vs and stats from /proc/net/ip_vs_stats
ipvs:
enabled: true
# Exposes load average. Darwin, Dragonfly, FreeBSD, Linux, NetBSD, OpenBSD, Solaris
loadavg:
enabled: true
# Exposes statistics about devices in /proc/mdstat (does nothing if no /proc/mdstat present)
mdadm:
enabled: true
# Exposes memory statistics.
meminfo:
enabled: true
# Exposes network interface statistics such as bytes transferred
netdev:
enabled: true
# Exposes network statistics from /proc/net/netstat
netstat:
enabled: true
# Exposes NFS client statistics from /proc/net/rpc/nfs
nfs:
enabled: true
# Exposes NFS kernel server statistics from /proc/net/rpc/nfsd
nfsd:
enabled: true
# Exposes various statistics from /proc/net/sockstat
sockstat:
enabled: true
# Exposes various statistics from /proc/stat
stat:
enabled: true
# Exposes statistics read from local disk
textfile:
enabled: true
# Exposes the current system time
time:
enabled: true
# Exposes selected adjtimex(2) system call stats
timex:
enabled: true
# Exposes system information as provided by the uname system call
uname:
enabled: true
# Exposes statistics from /proc/vmstat
vmstat:
enabled: true
# Exposes XFS runtime statistics
xfs:
enabled: true
# Exposes ZFS performance statistics
zfs:
enabled: true
##
# Enabled by default on Linux
##
# Exposes statistics of memory fragments as reported by /proc/buddyinfo
buddyinfo:
enabled: false
# Exposes Distributed Replicated Block Device statistics (to version 8.4)
drbd:
enabled: false
# Exposes detailed interrupts statistics
interrupts:
enabled: false
# Exposes kernel and system statistics from /sys/kernel/mm/ksm
ksmd:
enabled: false
# Exposes session counts from logind
logind:
enabled: false
# Exposes memory statistics from /proc/meminfo_numa
meminfo_numa:
enabled: false
# Exposes filesystem statistics from /proc/self/mountstats, exposes detailed NFS client statistics
mountstats:
enabled: false
# Exposes local NTP daemon health to check time
ntp:
enabled: false
# Exposes aggregate process statistics from /proc
processes:
enabled: false
# Exposes queuing discipline statistics
qdisc:
enabled: false
# Exposes service status from runit
runit:
enabled: false
# Exposes service status from supervisord
supervisord:
enabled: false
# Exposes service and system status from systemd
systemd:
enabled: false
# Exposes TCP connection status information from /proc/net/tcp and /proc/net/tcp6
tcpstat:
enabled: false
# Exposes WiFi device and station statistics
wifi:
enabled: false
apiVersion: v1
description: Creates Grafana instance for Kubernetes which maintaining by Rancher 2.
engine: gotpl
maintainers:
- name: thxCode
email: frank@rancher.com
name: grafana
version: 0.0.1
{"__requires":[{"type":"grafana","id":"grafana","name":"Grafana","version":"5.3.0"},{"type":"panel","id":"graph","name":"Graph","version":"5.0.0"},{"type":"datasource","id":"prometheus","name":"Prometheus","version":"5.0.0"},{"type":"panel","id":"singlestat","name":"Singlestat","version":"5.0.0"},{"type":"panel","id":"table","name":"Table","version":"5.0.0"}],"annotations":{"list":[{"builtIn":1,"datasource":"-- Grafana --","enable":true,"hide":true,"iconColor":"rgba(0, 211, 255, 1)","name":"Annotations & Alerts","type":"dashboard"}]},"description":"Monitors Kubernetes cluster using Prometheus. Shows overall cluster or Node CPU / Memory / Filesystem usage as well as individual pod, containers, systemd services statistics. Uses cAdvisor metrics only.","editable":true,"gnetId":1621,"graphTooltip":0,"iteration":1553900966707,"links":[],"panels":[{"collapsed":false,"gridPos":{"h":1,"w":24,"x":0,"y":0},"id":34,"panels":[],"title":"Total usage","type":"row"},{"cacheTimeout":null,"colorBackground":false,"colorValue":true,"colors":["rgba(50, 172, 45, 0.97)","rgba(237, 129, 40, 0.89)","rgba(245, 54, 54, 0.9)"],"datasource":"RANCHER_MONITORING","decimals":2,"editable":true,"error":false,"format":"percent","gauge":{"maxValue":100,"minValue":0,"show":true,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":5,"w":8,"x":0,"y":1},"height":"180px","id":6,"interval":null,"isNew":true,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"sum (rate (container_cpu_usage_seconds_total{id=\"/\",node=~\"^$Node$\"}[5m])) / sum (machine_cpu_cores{node=~\"^$Node$\"}) * 100","format":"time_series","interval":"10s","intervalFactor":1,"refId":"A","step":10}],"thresholds":"65, 90","title":"CPU usage (5m avg)","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":true,"colors":["rgba(50, 172, 45, 0.97)","rgba(237, 129, 40, 0.89)","rgba(245, 54, 54, 0.9)"],"datasource":"RANCHER_MONITORING","editable":true,"error":false,"format":"percent","gauge":{"maxValue":100,"minValue":0,"show":true,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":5,"w":8,"x":8,"y":1},"height":"180px","id":4,"interval":null,"isNew":true,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"sum (container_memory_working_set_bytes{id=\"/\",node=~\"^$Node$\"}) / sum (machine_memory_bytes{node=~\"^$Node$\"}) * 100","format":"time_series","interval":"10s","intervalFactor":1,"refId":"A","step":10}],"thresholds":"65, 90","title":"Memory usage","transparent":false,"type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":true,"colors":["rgba(50, 172, 45, 0.97)","rgba(237, 129, 40, 0.89)","rgba(245, 54, 54, 0.9)"],"datasource":"RANCHER_MONITORING","decimals":2,"editable":true,"error":false,"format":"percent","gauge":{"maxValue":100,"minValue":0,"show":true,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":5,"w":8,"x":16,"y":1},"height":"180px","id":7,"interval":null,"isNew":true,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"sum (container_fs_usage_bytes{device=~\"^/dev/.*$\",id=\"/\",node=~\"^$Node$\"}) / sum (container_fs_limit_bytes{device=~\"^/dev/.*$\",id=\"/\",node=~\"^$Node$\"}) * 100","format":"time_series","interval":"10s","intervalFactor":1,"legendFormat":"","metric":"","refId":"A","step":10}],"thresholds":"65, 90","title":"Filesystem usage","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(50, 172, 45, 0.97)","rgba(237, 129, 40, 0.89)","rgba(245, 54, 54, 0.9)"],"datasource":"RANCHER_MONITORING","decimals":2,"editable":true,"error":false,"format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":4,"x":0,"y":6},"height":"1px","id":11,"interval":null,"isNew":true,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":" cores","postfixFontSize":"30%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"sum (rate (container_cpu_usage_seconds_total{id=\"/\",node=~\"^$Node$\"}[5m]))","format":"time_series","interval":"10s","intervalFactor":1,"refId":"A","step":10}],"thresholds":"","title":"Used","type":"singlestat","valueFontSize":"50%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(50, 172, 45, 0.97)","rgba(237, 129, 40, 0.89)","rgba(245, 54, 54, 0.9)"],"datasource":"RANCHER_MONITORING","decimals":2,"editable":true,"error":false,"format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":4,"x":4,"y":6},"height":"1px","id":12,"interval":null,"isNew":true,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":" cores","postfixFontSize":"30%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"sum (machine_cpu_cores{node=~\"^$Node$\"})","interval":"10s","intervalFactor":1,"refId":"A","step":10}],"thresholds":"","title":"Total","type":"singlestat","valueFontSize":"50%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(50, 172, 45, 0.97)","rgba(237, 129, 40, 0.89)","rgba(245, 54, 54, 0.9)"],"datasource":"RANCHER_MONITORING","decimals":2,"editable":true,"error":false,"format":"bytes","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":4,"x":8,"y":6},"height":"1px","id":9,"interval":null,"isNew":true,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"20%","prefix":"","prefixFontSize":"20%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"sum (container_memory_working_set_bytes{id=\"/\",node=~\"^$Node$\"})","interval":"10s","intervalFactor":1,"refId":"A","step":10}],"thresholds":"","title":"Used","type":"singlestat","valueFontSize":"50%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(50, 172, 45, 0.97)","rgba(237, 129, 40, 0.89)","rgba(245, 54, 54, 0.9)"],"datasource":"RANCHER_MONITORING","decimals":2,"editable":true,"error":false,"format":"bytes","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":4,"x":12,"y":6},"height":"1px","id":10,"interval":null,"isNew":true,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"sum (machine_memory_bytes{node=~\"^$Node$\"})","interval":"10s","intervalFactor":1,"refId":"A","step":10}],"thresholds":"","title":"Total","type":"singlestat","valueFontSize":"50%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(50, 172, 45, 0.97)","rgba(237, 129, 40, 0.89)","rgba(245, 54, 54, 0.9)"],"datasource":"RANCHER_MONITORING","decimals":2,"editable":true,"error":false,"format":"bytes","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":4,"x":16,"y":6},"height":"1px","id":13,"interval":null,"isNew":true,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"sum (container_fs_usage_bytes{device=~\"^/dev/.*$\",id=\"/\",node=~\"^$Node$\"})","interval":"10s","intervalFactor":1,"refId":"A","step":10}],"thresholds":"","title":"Used","type":"singlestat","valueFontSize":"50%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(50, 172, 45, 0.97)","rgba(237, 129, 40, 0.89)","rgba(245, 54, 54, 0.9)"],"datasource":"RANCHER_MONITORING","decimals":2,"editable":true,"error":false,"format":"bytes","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":4,"x":20,"y":6},"height":"1px","id":14,"interval":null,"isNew":true,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"sum (container_fs_limit_bytes{device=~\"^/dev/.*$\",id=\"/\",node=~\"^$Node$\"})","interval":"10s","intervalFactor":1,"refId":"A","step":10}],"thresholds":"","title":"Total","type":"singlestat","valueFontSize":"50%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","fill":1,"gridPos":{"h":6,"w":8,"x":0,"y":9},"id":2051,"legend":{"avg":false,"current":false,"max":false,"min":false,"show":true,"total":false,"values":false},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum (rate (container_cpu_usage_seconds_total{id=\"/\",node=~\"^$Node$\"}[5m])) / sum (machine_cpu_cores{node=~\"^$Node$\"})","format":"time_series","hide":false,"instant":false,"intervalFactor":1,"legendFormat":"Cluster","refId":"A"},{"expr":"sum (rate (container_cpu_usage_seconds_total{id=\"/\"}[5m])) by (node) / sum (machine_cpu_cores) by (node)","format":"time_series","hide":false,"intervalFactor":1,"legendFormat":"{{node}}","refId":"B"}],"thresholds":[],"timeFrom":null,"timeRegions":[],"timeShift":null,"title":"CPU usage (5m avg)","tooltip":{"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"percentunit","label":"","logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":"","logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","fill":1,"gridPos":{"h":6,"w":8,"x":8,"y":9},"id":2052,"legend":{"avg":false,"current":false,"max":false,"min":false,"show":true,"total":false,"values":false},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum (container_memory_working_set_bytes{id=\"/\",node=~\"^$Node$\"}) / sum (machine_memory_bytes{node=~\"^$Node$\"}) * 100","format":"time_series","hide":false,"instant":false,"intervalFactor":1,"legendFormat":"Cluster","refId":"A"},{"expr":"sum (container_memory_working_set_bytes{id=\"/\"}) by (node) / sum (machine_memory_bytes) by (node) * 100","format":"time_series","hide":false,"intervalFactor":1,"legendFormat":"{{node}}","refId":"B"}],"thresholds":[],"timeFrom":null,"timeRegions":[],"timeShift":null,"title":"Memory usage","tooltip":{"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"percent","label":"","logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":"","logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","fill":1,"gridPos":{"h":6,"w":8,"x":16,"y":9},"id":2053,"legend":{"alignAsTable":false,"avg":false,"current":false,"max":false,"min":false,"rightSide":false,"show":true,"total":false,"values":false},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum (container_fs_usage_bytes{device=~\"^/dev/.*$\",id=\"/\",node=~\"^$Node$\"}) / sum (container_fs_limit_bytes{device=~\"^/dev/.*$\",id=\"/\",node=~\"^$Node$\"}) * 100","format":"time_series","hide":false,"instant":false,"intervalFactor":1,"legendFormat":"Cluster","refId":"A"},{"expr":"sum (container_fs_usage_bytes{device=~\"^/dev/.*$\",id=\"/\"}) by (node) / sum (container_fs_limit_bytes{device=~\"^/dev/.*$\",id=\"/\"}) by (node) * 100","format":"time_series","hide":false,"intervalFactor":1,"legendFormat":"{{node}}","refId":"B"}],"thresholds":[],"timeFrom":null,"timeRegions":[],"timeShift":null,"title":"Filesystem usage","tooltip":{"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"decimals":null,"format":"percent","label":"","logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":"","logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"collapsed":true,"gridPos":{"h":1,"w":24,"x":0,"y":15},"id":2022,"panels":[{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"fill":0,"gridPos":{"h":6,"w":12,"x":0,"y":16},"id":2058,"legend":{"avg":false,"current":false,"max":false,"min":false,"show":true,"total":false,"values":false},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[{"alias":"Total","fillBelowTo":"Unavailable"}],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum(kube_node_info{node=~\"$Node\"})","format":"time_series","intervalFactor":2,"legendFormat":"Total","refId":"A"},{"expr":"sum(kube_node_status_condition{condition=\"Ready\", node=~\"$Node\", status!=\"true\"})","format":"time_series","instant":false,"intervalFactor":2,"legendFormat":"Unavailable","refId":"B"}],"thresholds":[],"timeFrom":null,"timeRegions":[],"timeShift":null,"title":"Numbers","tooltip":{"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"decimals":0,"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"cacheTimeout":null,"colorBackground":true,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":4,"x":12,"y":16},"id":2056,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"sum(kube_node_status_condition{condition=\"DiskPressure\", node=~\"$Node\", status!=\"false\"})","format":"time_series","intervalFactor":1,"refId":"A"}],"thresholds":"1","title":"Disk Pressure","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":true,"colorPostfix":false,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":4,"x":16,"y":16},"id":2059,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"#0a50a1","full":true,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"sum(kube_node_status_condition{condition=\"MemoryPressure\", node=~\"$Node\", status!=\"false\"})","format":"time_series","intervalFactor":1,"refId":"A"}],"thresholds":"1","title":"Memory Pressure","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":true,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":4,"x":20,"y":16},"id":2061,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"sum(kube_node_status_condition{condition=\"PIDPressure\", node=~\"$Node\", status!=\"false\"})","format":"time_series","intervalFactor":1,"refId":"A"}],"thresholds":"1","title":"PID Pressure","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":true,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":4,"x":12,"y":19},"id":2026,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"sum(kube_node_spec_unschedulable{node=~\"$Node\"})","format":"time_series","intervalFactor":1,"refId":"A"}],"thresholds":"1","title":"Unschedulable","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":true,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":4,"x":16,"y":19},"id":2025,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"sum(kube_node_status_condition{condition=\"OutOfDisk\", node=~\"$Node\", status=\"true\"})","format":"time_series","intervalFactor":1,"refId":"A"}],"thresholds":"0","title":"Out of Disk","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":true,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","decimals":null,"format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":4,"x":20,"y":19},"id":2060,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"#bf1b00","show":true},"tableColumn":"","targets":[{"expr":"sum(kube_node_status_condition{condition=\"NetworkUnavailable\", node=~\"$Node\", status!=\"false\"})","format":"time_series","intervalFactor":1,"refId":"A"}],"thresholds":"1","title":"Network Unavailable","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"}],"title":"Node","type":"row"},{"collapsed":true,"gridPos":{"h":1,"w":24,"x":0,"y":16},"id":2014,"panels":[{"columns":[{"text":"Current","value":"current"}],"datasource":"RANCHER_MONITORING","fontSize":"100%","gridPos":{"h":5,"w":6,"x":0,"y":17},"id":2016,"links":[],"pageSize":null,"scroll":true,"showHeader":true,"sort":{"col":1,"desc":true},"styles":[{"alias":"Time","dateFormat":"YYYY-MM-DD HH:mm:ss","pattern":"Time","type":"date"},{"alias":"","colorMode":"row","colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"decimals":0,"pattern":"Metric","thresholds":["0","0",".9"],"type":"string","unit":"none"},{"alias":"","colorMode":"row","colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"dateFormat":"YYYY-MM-DD HH:mm:ss","decimals":0,"link":false,"pattern":"Value","thresholds":["0","1"],"type":"number","unit":"none"}],"targets":[{"expr":"kube_deployment_status_replicas{namespace=~\".*\"}","format":"time_series","instant":true,"interval":"","intervalFactor":1,"legendFormat":"{{ deployment }}","refId":"A"}],"title":"Deployment Replicas - Up To Date","transform":"timeseries_to_rows","type":"table"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":5,"w":6,"x":6,"y":17},"id":2018,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"sum(kube_deployment_status_replicas{namespace=~\".*\"})","format":"time_series","intervalFactor":1,"refId":"A"}],"thresholds":"","title":"Deployment Replicas","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"avg"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":5,"w":6,"x":12,"y":17},"id":2019,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"sum(kube_deployment_status_replicas_updated{namespace=~\".*\"})","format":"time_series","intervalFactor":1,"refId":"A"}],"thresholds":"","title":"Deployment Replicas - Updated","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"avg"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":5,"w":6,"x":18,"y":17},"id":2020,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"sum(kube_deployment_status_replicas_unavailable{namespace=~\".*\"})","format":"time_series","intervalFactor":1,"refId":"A"}],"thresholds":"","title":"Deployment Replicas - Unavailable","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"avg"}],"title":"Deployments","type":"row"},{"collapsed":true,"gridPos":{"h":1,"w":24,"x":0,"y":17},"id":2045,"panels":[{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":8,"x":0,"y":18},"id":2047,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"sum(kube_job_status_succeeded{namespace=~\".*\"})","format":"time_series","intervalFactor":1,"refId":"A"}],"thresholds":"","title":"Jobs Succeeded","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":8,"x":8,"y":18},"id":2048,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"sum(kube_job_status_active{namespace=~\".*\"})","format":"time_series","intervalFactor":1,"refId":"A"}],"thresholds":"","title":"Jobs Succeeded","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":8,"x":16,"y":18},"id":2049,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"sum(kube_job_status_failed{namespace=~\".*\"})","format":"time_series","intervalFactor":1,"refId":"A"}],"thresholds":"","title":"Jobs Failed","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"}],"title":"Jobs","type":"row"},{"collapsed":true,"gridPos":{"h":1,"w":24,"x":0,"y":18},"id":2028,"panels":[{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":12,"x":0,"y":19},"id":2030,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(78, 203, 42, 0.28)","full":false,"lineColor":"#629e51","show":true},"tableColumn":"","targets":[{"expr":"sum(kube_pod_status_phase{namespace=~\".*\", phase=\"Running\"})","format":"time_series","interval":"","intervalFactor":1,"refId":"A"}],"thresholds":"","title":"Pods Running","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":12,"x":12,"y":19},"id":2031,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(78, 203, 42, 0.28)","full":false,"lineColor":"#629e51","show":true},"tableColumn":"","targets":[{"expr":"sum(kube_pod_status_phase{namespace=~\".*\", phase=\"Pending\"})","format":"time_series","interval":"","intervalFactor":1,"refId":"A"}],"thresholds":"","title":"Pods Pending","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":8,"x":0,"y":22},"id":2032,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(78, 203, 42, 0.28)","full":false,"lineColor":"#629e51","show":true},"tableColumn":"","targets":[{"expr":"sum(kube_pod_status_phase{namespace=~\".*\", phase=\"Failed\"})","format":"time_series","interval":"","intervalFactor":1,"refId":"A"}],"thresholds":"","title":"Pods Failed","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":8,"x":8,"y":22},"id":2033,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(78, 203, 42, 0.28)","full":false,"lineColor":"#629e51","show":true},"tableColumn":"","targets":[{"expr":"sum(kube_pod_status_phase{namespace=~\".*\", phase=\"Succeeded\"})","format":"time_series","interval":"","intervalFactor":1,"refId":"A"}],"thresholds":"","title":"Pods Succeeded","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":8,"x":16,"y":22},"id":2034,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(78, 203, 42, 0.28)","full":false,"lineColor":"#629e51","show":true},"tableColumn":"","targets":[{"expr":"sum(kube_pod_status_phase{namespace=~\".*\", phase=\"Unknown\"})","format":"time_series","interval":"","intervalFactor":1,"refId":"A"}],"thresholds":"","title":"Pods Unknown","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"}],"title":"Pods","type":"row"},{"collapsed":true,"gridPos":{"h":1,"w":24,"x":0,"y":19},"id":2036,"panels":[{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":6,"x":0,"y":20},"id":2038,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"sum(kube_pod_container_status_running{namespace=~\".*\"})","format":"time_series","intervalFactor":1,"refId":"A"}],"thresholds":"","title":"Containers Running","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":6,"x":6,"y":20},"id":2039,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"sum(kube_pod_container_status_waiting{namespace=~\".*\"})","format":"time_series","intervalFactor":1,"refId":"A"}],"thresholds":"","title":"Containers Waiting","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":6,"x":12,"y":20},"id":2040,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"sum(kube_pod_container_status_terminated{namespace=~\".*\"})","format":"time_series","intervalFactor":1,"refId":"A"}],"thresholds":"","title":"Containers Terminated","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":6,"x":18,"y":20},"id":2041,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"sum(delta(kube_pod_container_status_restarts{namespace=\"kube-system\"}[30m]))","format":"time_series","intervalFactor":1,"refId":"A"}],"thresholds":"","title":"Containers Restarts (Last 30 Minutes)","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":12,"x":0,"y":23},"id":2043,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"sum(kube_pod_container_resource_requests_cpu_cores{namespace=~\".*\", node=~\"$Node\"})","format":"time_series","intervalFactor":1,"refId":"A"}],"thresholds":"","title":"CPU Cores Requested by Containers","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","format":"decbytes","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":12,"x":12,"y":23},"id":2042,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"sum(kube_pod_container_resource_requests_memory_bytes{namespace=~\".*\", node=~\"$Node\"})","format":"time_series","intervalFactor":1,"refId":"A"}],"thresholds":"","title":"Memory Requested By Containers","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"}],"title":"Containers","type":"row"},{"collapsed":true,"gridPos":{"h":1,"w":24,"x":0,"y":20},"id":33,"panels":[{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","decimals":2,"editable":true,"error":false,"fill":1,"grid":{},"gridPos":{"h":5,"w":24,"x":0,"y":21},"height":"200px","id":32,"isNew":true,"legend":{"alignAsTable":false,"avg":true,"current":true,"max":false,"min":false,"rightSide":false,"show":false,"sideWidth":200,"sort":"current","sortDesc":true,"total":false,"values":true},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum (rate (container_network_receive_bytes_total{node=~\"^$Node$\"}[5m]))","format":"time_series","interval":"10s","intervalFactor":1,"legendFormat":"Received","metric":"network","refId":"A","step":10},{"expr":"- sum (rate (container_network_transmit_bytes_total{node=~\"^$Node$\"}[5m]))","format":"time_series","interval":"10s","intervalFactor":1,"legendFormat":"Sent","metric":"network","refId":"B","step":10}],"thresholds":[],"timeFrom":null,"timeRegions":[],"timeShift":null,"title":"Network I/O pressure","tooltip":{"msResolution":false,"shared":true,"sort":0,"value_type":"cumulative"},"transparent":false,"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"Bps","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"Bps","label":null,"logBase":1,"max":null,"min":null,"show":false}],"yaxis":{"align":false,"alignLevel":null}}],"title":"Network I/O pressure","type":"row"},{"collapsed":true,"gridPos":{"h":1,"w":24,"x":0,"y":21},"id":35,"panels":[{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","decimals":3,"editable":true,"error":false,"fill":0,"grid":{},"gridPos":{"h":7,"w":24,"x":0,"y":22},"height":"","id":17,"isNew":true,"legend":{"alignAsTable":true,"avg":true,"current":true,"max":false,"min":false,"rightSide":true,"show":true,"sort":"current","sortDesc":true,"total":false,"values":true},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":true,"targets":[{"expr":"sum (rate (container_cpu_usage_seconds_total{image!=\"\",name=~\"^k8s_.*\",node=~\"^$Node$\"}[5m])) by (pod_name)","format":"time_series","interval":"10s","intervalFactor":1,"legendFormat":"{{ pod_name }}","metric":"container_cpu","refId":"A","step":10}],"thresholds":[],"timeFrom":null,"timeRegions":[],"timeShift":null,"title":"Pods CPU usage (5m avg)","tooltip":{"msResolution":true,"shared":true,"sort":2,"value_type":"cumulative"},"transparent":false,"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"percentunit","label":"cores","logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":false}],"yaxis":{"align":false,"alignLevel":null}}],"title":"Pods CPU usage","type":"row"},{"collapsed":true,"gridPos":{"h":1,"w":24,"x":0,"y":22},"id":36,"panels":[{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","decimals":3,"editable":true,"error":false,"fill":0,"grid":{},"gridPos":{"h":7,"w":24,"x":0,"y":23},"height":"","id":23,"isNew":true,"legend":{"alignAsTable":true,"avg":true,"current":true,"max":false,"min":false,"rightSide":true,"show":true,"sort":"current","sortDesc":true,"total":false,"values":true},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":true,"targets":[{"expr":"sum (rate (container_cpu_usage_seconds_total{systemd_service_name!=\"\",node=~\"^$Node$\"}[5m])) by (systemd_service_name)","format":"time_series","hide":false,"interval":"10s","intervalFactor":1,"legendFormat":"{{ systemd_service_name }}","metric":"container_cpu","refId":"A","step":10}],"thresholds":[],"timeFrom":null,"timeRegions":[],"timeShift":null,"title":"System services CPU usage (5m avg)","tooltip":{"msResolution":true,"shared":true,"sort":2,"value_type":"cumulative"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"percentunit","label":"cores","logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":false}],"yaxis":{"align":false,"alignLevel":null}}],"title":"System services CPU usage","type":"row"},{"collapsed":true,"gridPos":{"h":1,"w":24,"x":0,"y":23},"id":37,"panels":[{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","decimals":3,"editable":true,"error":false,"fill":0,"grid":{},"gridPos":{"h":7,"w":24,"x":0,"y":24},"height":"","id":24,"isNew":true,"legend":{"alignAsTable":true,"avg":true,"current":true,"hideEmpty":false,"hideZero":false,"max":false,"min":false,"rightSide":true,"show":true,"sideWidth":null,"sort":"current","sortDesc":true,"total":false,"values":true},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":true,"targets":[{"expr":"sum (rate (container_cpu_usage_seconds_total{image!=\"\",name=~\"^k8s_.*\",container_name!=\"POD\",node=~\"^$Node$\"}[5m])) by (container_name, pod_name)","format":"time_series","hide":false,"interval":"10s","intervalFactor":1,"legendFormat":"pod: {{ pod_name }} | {{ container_name }}","metric":"container_cpu","refId":"A","step":10},{"expr":"sum (rate (container_cpu_usage_seconds_total{image!=\"\",name!~\"^k8s_.*\",node=~\"^$Node$\"}[5m])) by (node, name, image)","format":"time_series","hide":false,"interval":"10s","intervalFactor":1,"legendFormat":"docker: {{ node }} | {{ image }} ({{ name }})","metric":"container_cpu","refId":"B","step":10},{"expr":"sum (rate (container_cpu_usage_seconds_total{rkt_container_name!=\"\",node=~\"^$Node$\"}[5m])) by (node, rkt_container_name)","format":"time_series","interval":"10s","intervalFactor":1,"legendFormat":"rkt: {{ node }} | {{ rkt_container_name }}","metric":"container_cpu","refId":"C","step":10}],"thresholds":[],"timeFrom":null,"timeRegions":[],"timeShift":null,"title":"Containers CPU usage (5m avg)","tooltip":{"msResolution":true,"shared":true,"sort":2,"value_type":"cumulative"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"percentunit","label":"cores","logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":false}],"yaxis":{"align":false,"alignLevel":null}}],"title":"Containers CPU usage","type":"row"},{"collapsed":true,"gridPos":{"h":1,"w":24,"x":0,"y":24},"id":38,"panels":[{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","decimals":3,"editable":true,"error":false,"fill":0,"grid":{},"gridPos":{"h":13,"w":24,"x":0,"y":25},"id":20,"isNew":true,"legend":{"alignAsTable":true,"avg":true,"current":true,"max":false,"min":false,"rightSide":false,"show":true,"sort":"current","sortDesc":true,"total":false,"values":true},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":true,"targets":[{"expr":"sum (rate (container_cpu_usage_seconds_total{id!=\"/\",node=~\"^$Node$\"}[5m])) by (id)","format":"time_series","hide":false,"interval":"10s","intervalFactor":1,"legendFormat":"{{ id }}","metric":"container_cpu","refId":"A","step":10}],"thresholds":[],"timeFrom":null,"timeRegions":[],"timeShift":null,"title":"All processes CPU usage (5m avg)","tooltip":{"msResolution":true,"shared":true,"sort":2,"value_type":"cumulative"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"percentunit","label":"cores","logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":false}],"yaxis":{"align":false,"alignLevel":null}}],"repeat":null,"title":"All processes CPU usage","type":"row"},{"collapsed":true,"gridPos":{"h":1,"w":24,"x":0,"y":25},"id":39,"panels":[{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","decimals":2,"editable":true,"error":false,"fill":0,"grid":{},"gridPos":{"h":7,"w":24,"x":0,"y":26},"id":25,"isNew":true,"legend":{"alignAsTable":true,"avg":true,"current":true,"max":false,"min":false,"rightSide":true,"show":true,"sideWidth":200,"sort":"current","sortDesc":true,"total":false,"values":true},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":true,"targets":[{"expr":"sum (container_memory_working_set_bytes{image!=\"\",name=~\"^k8s_.*\",node=~\"^$Node$\"}) by (pod_name)","format":"time_series","interval":"10s","intervalFactor":1,"legendFormat":"{{ pod_name }}","metric":"container_memory_usage:sort_desc","refId":"A","step":10}],"thresholds":[],"timeFrom":null,"timeRegions":[],"timeShift":null,"title":"Pods memory usage","tooltip":{"msResolution":false,"shared":true,"sort":2,"value_type":"cumulative"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"bytes","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":false}],"yaxis":{"align":false,"alignLevel":null}}],"title":"Pods memory usage","type":"row"},{"collapsed":true,"gridPos":{"h":1,"w":24,"x":0,"y":26},"id":40,"panels":[{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","decimals":2,"editable":true,"error":false,"fill":0,"grid":{},"gridPos":{"h":7,"w":24,"x":0,"y":27},"id":26,"isNew":true,"legend":{"alignAsTable":true,"avg":true,"current":true,"max":false,"min":false,"rightSide":true,"show":true,"sideWidth":200,"sort":"current","sortDesc":true,"total":false,"values":true},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":true,"targets":[{"expr":"sum (container_memory_working_set_bytes{systemd_service_name!=\"\",node=~\"^$Node$\"}) by (systemd_service_name)","interval":"10s","intervalFactor":1,"legendFormat":"{{ systemd_service_name }}","metric":"container_memory_usage:sort_desc","refId":"A","step":10}],"thresholds":[],"timeFrom":null,"timeRegions":[],"timeShift":null,"title":"System services memory usage","tooltip":{"msResolution":false,"shared":true,"sort":2,"value_type":"cumulative"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"bytes","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":false}],"yaxis":{"align":false,"alignLevel":null}}],"title":"System services memory usage","type":"row"},{"collapsed":true,"gridPos":{"h":1,"w":24,"x":0,"y":27},"id":41,"panels":[{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","decimals":2,"editable":true,"error":false,"fill":0,"grid":{},"gridPos":{"h":7,"w":24,"x":0,"y":28},"id":27,"isNew":true,"legend":{"alignAsTable":true,"avg":true,"current":true,"max":false,"min":false,"rightSide":true,"show":true,"sideWidth":200,"sort":"current","sortDesc":true,"total":false,"values":true},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":true,"targets":[{"expr":"sum (container_memory_working_set_bytes{image!=\"\",name=~\"^k8s_.*\",container_name!=\"POD\",node=~\"^$Node$\"}) by (container_name, pod_name)","interval":"10s","intervalFactor":1,"legendFormat":"pod: {{ pod_name }} | {{ container_name }}","metric":"container_memory_usage:sort_desc","refId":"A","step":10},{"expr":"sum (container_memory_working_set_bytes{image!=\"\",name!~\"^k8s_.*\",node=~\"^$Node$\"}) by (node, name, image)","interval":"10s","intervalFactor":1,"legendFormat":"docker: {{ node }} | {{ image }} ({{ name }})","metric":"container_memory_usage:sort_desc","refId":"B","step":10},{"expr":"sum (container_memory_working_set_bytes{rkt_container_name!=\"\",node=~\"^$Node$\"}) by (node, rkt_container_name)","interval":"10s","intervalFactor":1,"legendFormat":"rkt: {{ node }} | {{ rkt_container_name }}","metric":"container_memory_usage:sort_desc","refId":"C","step":10}],"thresholds":[],"timeFrom":null,"timeRegions":[],"timeShift":null,"title":"Containers memory usage","tooltip":{"msResolution":false,"shared":true,"sort":2,"value_type":"cumulative"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"bytes","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":false}],"yaxis":{"align":false,"alignLevel":null}}],"title":"Containers memory usage","type":"row"},{"collapsed":true,"gridPos":{"h":1,"w":24,"x":0,"y":28},"id":42,"panels":[{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","decimals":2,"editable":true,"error":false,"fill":0,"grid":{},"gridPos":{"h":13,"w":24,"x":0,"y":29},"id":28,"isNew":true,"legend":{"alignAsTable":true,"avg":true,"current":true,"max":false,"min":false,"rightSide":false,"show":true,"sideWidth":200,"sort":"current","sortDesc":true,"total":false,"values":true},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":true,"targets":[{"expr":"sum (container_memory_working_set_bytes{id!=\"/\",node=~\"^$Node$\"}) by (id)","interval":"10s","intervalFactor":1,"legendFormat":"{{ id }}","metric":"container_memory_usage:sort_desc","refId":"A","step":10}],"thresholds":[],"timeFrom":null,"timeRegions":[],"timeShift":null,"title":"All processes memory usage","tooltip":{"msResolution":false,"shared":true,"sort":2,"value_type":"cumulative"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"bytes","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":false}],"yaxis":{"align":false,"alignLevel":null}}],"title":"All processes memory usage","type":"row"},{"collapsed":true,"gridPos":{"h":1,"w":24,"x":0,"y":29},"id":43,"panels":[{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","decimals":2,"editable":true,"error":false,"fill":1,"grid":{},"gridPos":{"h":7,"w":24,"x":0,"y":30},"id":16,"isNew":true,"legend":{"alignAsTable":true,"avg":true,"current":true,"max":false,"min":false,"rightSide":true,"show":true,"sideWidth":200,"sort":"current","sortDesc":true,"total":false,"values":true},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum (rate (container_network_receive_bytes_total{image!=\"\",name=~\"^k8s_.*\",node=~\"^$Node$\"}[5m])) by (pod_name)","interval":"10s","intervalFactor":1,"legendFormat":"-> {{ pod_name }}","metric":"network","refId":"A","step":10},{"expr":"- sum (rate (container_network_transmit_bytes_total{image!=\"\",name=~\"^k8s_.*\",node=~\"^$Node$\"}[5m])) by (pod_name)","interval":"10s","intervalFactor":1,"legendFormat":"<- {{ pod_name }}","metric":"network","refId":"B","step":10}],"thresholds":[],"timeFrom":null,"timeRegions":[],"timeShift":null,"title":"Pods network I/O (5m avg)","tooltip":{"msResolution":false,"shared":true,"sort":2,"value_type":"cumulative"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"Bps","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":false}],"yaxis":{"align":false,"alignLevel":null}}],"title":"Pods network I/O","type":"row"},{"collapsed":true,"gridPos":{"h":1,"w":24,"x":0,"y":30},"id":44,"panels":[{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","decimals":2,"editable":true,"error":false,"fill":1,"grid":{},"gridPos":{"h":7,"w":24,"x":0,"y":17},"id":30,"isNew":true,"legend":{"alignAsTable":true,"avg":true,"current":true,"max":false,"min":false,"rightSide":true,"show":true,"sideWidth":200,"sort":"current","sortDesc":true,"total":false,"values":true},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum (rate (container_network_receive_bytes_total{image!=\"\",name=~\"^k8s_.*\",node=~\"^$Node$\"}[5m])) by (container_name, pod_name)","hide":false,"interval":"10s","intervalFactor":1,"legendFormat":"-> pod: {{ pod_name }} | {{ container_name }}","metric":"network","refId":"B","step":10},{"expr":"- sum (rate (container_network_transmit_bytes_total{image!=\"\",name=~\"^k8s_.*\",node=~\"^$Node$\"}[5m])) by (container_name, pod_name)","hide":false,"interval":"10s","intervalFactor":1,"legendFormat":"<- pod: {{ pod_name }} | {{ container_name }}","metric":"network","refId":"D","step":10},{"expr":"sum (rate (container_network_receive_bytes_total{image!=\"\",name!~\"^k8s_.*\",node=~\"^$Node$\"}[5m])) by (node, name, image)","hide":false,"interval":"10s","intervalFactor":1,"legendFormat":"-> docker: {{ node }} | {{ image }} ({{ name }})","metric":"network","refId":"A","step":10},{"expr":"- sum (rate (container_network_transmit_bytes_total{image!=\"\",name!~\"^k8s_.*\",node=~\"^$Node$\"}[5m])) by (node, name, image)","hide":false,"interval":"10s","intervalFactor":1,"legendFormat":"<- docker: {{ node }} | {{ image }} ({{ name }})","metric":"network","refId":"C","step":10},{"expr":"sum (rate (container_network_transmit_bytes_total{rkt_container_name!=\"\",node=~\"^$Node$\"}[5m])) by (node, rkt_container_name)","hide":false,"interval":"10s","intervalFactor":1,"legendFormat":"-> rkt: {{ node }} | {{ rkt_container_name }}","metric":"network","refId":"E","step":10},{"expr":"- sum (rate (container_network_transmit_bytes_total{rkt_container_name!=\"\",node=~\"^$Node$\"}[5m])) by (node, rkt_container_name)","hide":false,"interval":"10s","intervalFactor":1,"legendFormat":"<- rkt: {{ node }} | {{ rkt_container_name }}","metric":"network","refId":"F","step":10}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Containers network I/O (5m avg)","tooltip":{"msResolution":false,"shared":true,"sort":2,"value_type":"cumulative"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"Bps","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":false}]}],"title":"Containers network I/O","type":"row"},{"collapsed":true,"gridPos":{"h":1,"w":24,"x":0,"y":31},"id":45,"panels":[{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","decimals":2,"editable":true,"error":false,"fill":1,"grid":{},"gridPos":{"h":13,"w":24,"x":0,"y":18},"id":29,"isNew":true,"legend":{"alignAsTable":true,"avg":true,"current":true,"max":false,"min":false,"rightSide":false,"show":true,"sideWidth":200,"sort":"current","sortDesc":true,"total":false,"values":true},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum (rate (container_network_receive_bytes_total{id!=\"/\",node=~\"^$Node$\"}[5m])) by (id)","interval":"10s","intervalFactor":1,"legendFormat":"-> {{ id }}","metric":"network","refId":"A","step":10},{"expr":"- sum (rate (container_network_transmit_bytes_total{id!=\"/\",node=~\"^$Node$\"}[5m])) by (id)","interval":"10s","intervalFactor":1,"legendFormat":"<- {{ id }}","metric":"network","refId":"B","step":10}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"All processes network I/O (5m avg)","tooltip":{"msResolution":false,"shared":true,"sort":2,"value_type":"cumulative"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"Bps","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":false}]}],"title":"All processes network I/O","type":"row"}],"refresh":"1m","schemaVersion":16,"style":"dark","tags":[],"templating":{"list":[{"allValue":".*","current":{"text":"All","value":"$__all"},"datasource":"RANCHER_MONITORING","definition":"","hide":0,"includeAll":true,"label":null,"multi":false,"name":"Node","options":[],"query":"label_values(node_boot_time_seconds, node)","refresh":1,"regex":"","skipUrlSync":false,"sort":0,"tagValuesQuery":"","tags":[],"tagsQuery":"","type":"query","useTags":false}]},"time":{"from":"now-30m","to":"now"},"timepicker":{"refresh_intervals":["5s","10s","30s","1m","5m","15m","30m","1h","2h","1d"],"time_options":["5m","15m","1h","6h","12h","24h","2d","7d","30d"]},"timezone":"browser","title":"Cluster","uid":"icjpCppik","version":1}
\ No newline at end of file
{"__requires":[{"type":"grafana","id":"grafana","name":"Grafana","version":"5.3.0"},{"type":"panel","id":"graph","name":"Graph","version":"5.0.0"},{"type":"datasource","id":"prometheus","name":"Prometheus","version":"5.0.0"},{"type":"panel","id":"singlestat","name":"Singlestat","version":"5.0.0"}],"annotations":{"list":[{"builtIn":1,"datasource":"-- Grafana --","enable":true,"hide":true,"iconColor":"rgba(0, 211, 255, 1)","name":"Annotations & Alerts","type":"dashboard"}]},"description":"Etcd Dashboard for Prometheus metrics scraper","editable":true,"gnetId":3070,"graphTooltip":0,"id":null,"links":[],"panels":[{"cacheTimeout":null,"colorBackground":false,"colorValue":true,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":7,"w":8,"x":0,"y":0},"id":44,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"max(etcd_server_has_leader)","format":"time_series","intervalFactor":2,"refId":"A","step":600}],"thresholds":"0,1","title":"Etcd has a leader?","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"YES","value":"1"},{"op":"=","text":"NO","value":"0"}],"valueName":"avg"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":7,"w":8,"x":8,"y":0},"id":42,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"max(etcd_server_leader_changes_seen_total)","format":"time_series","intervalFactor":2,"refId":"A","step":600}],"thresholds":"","title":"The number of leader changes seen","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"avg"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":7,"w":8,"x":16,"y":0},"id":43,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"max(etcd_server_leader_changes_seen_total)","format":"time_series","intervalFactor":2,"refId":"A","step":600}],"thresholds":"","title":"The total number of failed proposals seen","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"avg"},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","editable":true,"error":false,"fill":0,"gridPos":{"h":7,"w":12,"x":0,"y":7},"id":23,"legend":{"avg":false,"current":false,"max":false,"min":false,"show":false,"total":false,"values":false},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum(rate(grpc_server_started_total{grpc_type=\"unary\"}[5m]))","format":"time_series","intervalFactor":2,"legendFormat":"RPC Rate","metric":"grpc_server_started_total","refId":"A","step":60},{"expr":"sum(rate(grpc_server_handled_total{grpc_type=\"unary\",grpc_code!=\"OK\"}[5m]))","format":"time_series","intervalFactor":2,"legendFormat":"RPC Failed Rate","metric":"grpc_server_handled_total","refId":"B","step":60}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"RPC Rate","tooltip":{"msResolution":false,"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"ops","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","editable":true,"error":false,"fill":0,"gridPos":{"h":7,"w":12,"x":12,"y":7},"id":41,"legend":{"avg":false,"current":false,"max":false,"min":false,"show":false,"total":false,"values":false},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":true,"steppedLine":false,"targets":[{"expr":"sum(grpc_server_started_total{grpc_service=\"etcdserverpb.Watch\",grpc_type=\"bidi_stream\"}) - sum(grpc_server_handled_total{grpc_service=\"etcdserverpb.Watch\",grpc_type=\"bidi_stream\"})","format":"time_series","intervalFactor":2,"legendFormat":"Watch Streams","metric":"grpc_server_handled_total","refId":"A","step":60},{"expr":"sum(grpc_server_started_total{grpc_service=\"etcdserverpb.Lease\",grpc_type=\"bidi_stream\"}) - sum(grpc_server_handled_total{grpc_service=\"etcdserverpb.Lease\",grpc_type=\"bidi_stream\"})","format":"time_series","intervalFactor":2,"legendFormat":"Lease Streams","metric":"grpc_server_handled_total","refId":"B","step":60}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Active Streams","tooltip":{"msResolution":false,"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"short","label":"","logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","decimals":null,"editable":true,"error":false,"fill":0,"grid":{},"gridPos":{"h":7,"w":8,"x":0,"y":14},"id":1,"legend":{"avg":false,"current":false,"max":false,"min":false,"show":false,"total":false,"values":false},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum(etcd_debugging_mvcc_db_total_size_in_bytes)","format":"time_series","hide":false,"interval":"","intervalFactor":2,"legendFormat":"{{instance}} DB Size","metric":"","refId":"A","step":120}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"DB Size","tooltip":{"msResolution":false,"shared":true,"sort":0,"value_type":"cumulative"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"bytes","logBase":1,"max":null,"min":null,"show":true},{"format":"short","logBase":1,"max":null,"min":null,"show":false}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","editable":true,"error":false,"fill":0,"grid":{},"gridPos":{"h":7,"w":8,"x":8,"y":14},"id":3,"legend":{"avg":false,"current":false,"max":false,"min":false,"show":false,"total":false,"values":false},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":1,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":true,"targets":[{"expr":"histogram_quantile(0.99, sum(rate(etcd_disk_wal_fsync_duration_seconds_bucket[5m])) by (instance, le))","format":"time_series","hide":false,"intervalFactor":2,"legendFormat":"{{instance}} WAL fsync","metric":"etcd_disk_wal_fsync_duration_seconds_bucket","refId":"A","step":120},{"expr":"histogram_quantile(0.99, sum(rate(etcd_disk_backend_commit_duration_seconds_bucket[5m])) by (instance, le))","format":"time_series","intervalFactor":2,"legendFormat":"{{instance}} DB fsync","metric":"etcd_disk_backend_commit_duration_seconds_bucket","refId":"B","step":120}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Disk Sync Duration","tooltip":{"msResolution":false,"shared":true,"sort":0,"value_type":"cumulative"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"s","logBase":1,"max":null,"min":null,"show":true},{"format":"short","logBase":1,"max":null,"min":null,"show":false}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","editable":true,"error":false,"fill":0,"gridPos":{"h":7,"w":8,"x":16,"y":14},"id":29,"legend":{"avg":false,"current":false,"max":false,"min":false,"show":false,"total":false,"values":false},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"process_resident_memory_bytes","format":"time_series","intervalFactor":2,"legendFormat":"{{instance}} Resident Memory","metric":"process_resident_memory_bytes","refId":"A","step":120}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Memory","tooltip":{"msResolution":false,"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"bytes","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","editable":true,"error":false,"fill":5,"gridPos":{"h":7,"w":6,"x":0,"y":21},"id":22,"legend":{"avg":false,"current":false,"max":false,"min":false,"show":false,"total":false,"values":false},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":true,"steppedLine":false,"targets":[{"expr":"sum(rate(etcd_network_client_grpc_received_bytes_total[5m]))","format":"time_series","intervalFactor":2,"legendFormat":"{{instance}} Client Traffic In","metric":"etcd_network_client_grpc_received_bytes_total","refId":"A","step":120}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Client Traffic In","tooltip":{"msResolution":false,"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"Bps","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","editable":true,"error":false,"fill":5,"gridPos":{"h":7,"w":6,"x":6,"y":21},"id":21,"legend":{"avg":false,"current":false,"max":false,"min":false,"show":false,"total":false,"values":false},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":true,"steppedLine":false,"targets":[{"expr":"rate(etcd_network_client_grpc_sent_bytes_total[5m])","format":"time_series","intervalFactor":2,"legendFormat":"{{instance}} Client Traffic Out","metric":"etcd_network_client_grpc_sent_bytes_total","refId":"A","step":120}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Client Traffic Out","tooltip":{"msResolution":false,"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"Bps","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","editable":true,"error":false,"fill":0,"gridPos":{"h":7,"w":6,"x":12,"y":21},"id":20,"legend":{"avg":false,"current":false,"max":false,"min":false,"show":false,"total":false,"values":false},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum(rate(etcd_network_peer_received_bytes_total[5m])) by (instance)","format":"time_series","intervalFactor":2,"legendFormat":"{{instance}} Peer Traffic In","metric":"etcd_network_peer_received_bytes_total","refId":"A","step":120}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Peer Traffic In","tooltip":{"msResolution":false,"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"Bps","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","decimals":null,"editable":true,"error":false,"fill":0,"grid":{},"gridPos":{"h":7,"w":6,"x":18,"y":21},"id":16,"legend":{"avg":false,"current":false,"max":false,"min":false,"show":false,"total":false,"values":false},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum(rate(etcd_network_peer_sent_bytes_total[5m])) by (instance)","format":"time_series","hide":false,"interval":"","intervalFactor":2,"legendFormat":"{{instance}} Peer Traffic Out","metric":"etcd_network_peer_sent_bytes_total","refId":"A","step":120}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Peer Traffic Out","tooltip":{"msResolution":false,"shared":true,"sort":0,"value_type":"cumulative"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"Bps","logBase":1,"max":null,"min":null,"show":true},{"format":"short","logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","editable":true,"error":false,"fill":0,"gridPos":{"h":7,"w":12,"x":0,"y":28},"id":40,"legend":{"avg":false,"current":false,"max":false,"min":false,"show":false,"total":false,"values":false},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum(rate(etcd_server_proposals_failed_total[5m]))","format":"time_series","intervalFactor":2,"legendFormat":"Proposal Failure Rate","metric":"etcd_server_proposals_failed_total","refId":"A","step":60},{"expr":"sum(etcd_server_proposals_pending)","format":"time_series","intervalFactor":2,"legendFormat":"Proposal Pending Total","metric":"etcd_server_proposals_pending","refId":"B","step":60},{"expr":"sum(rate(etcd_server_proposals_committed_total[5m]))","format":"time_series","intervalFactor":2,"legendFormat":"Proposal Commit Rate","metric":"etcd_server_proposals_committed_total","refId":"C","step":60},{"expr":"sum(rate(etcd_server_proposals_applied_total[5m]))","format":"time_series","intervalFactor":2,"legendFormat":"Proposal Apply Rate","refId":"D","step":60}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Raft Proposals","tooltip":{"msResolution":false,"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"short","label":"","logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","decimals":0,"editable":true,"error":false,"fill":0,"gridPos":{"h":7,"w":12,"x":12,"y":28},"id":19,"legend":{"alignAsTable":false,"avg":false,"current":false,"max":false,"min":false,"rightSide":false,"show":false,"total":false,"values":false},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"changes(etcd_server_leader_changes_seen_total[1d])","format":"time_series","intervalFactor":2,"legendFormat":"{{instance}} Total Leader Elections Per Day","metric":"etcd_server_leader_changes_seen_total","refId":"A","step":60}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Total Leader Elections Per Day","tooltip":{"msResolution":false,"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","description":"proposals_committed_total records the total number of consensus proposals committed. This gauge should increase over time if the cluster is healthy. Several healthy members of an etcd cluster may have different total committed proposals at once. This discrepancy may be due to recovering from peers after starting, lagging behind the leader, or being the leader and therefore having the most commits. It is important to monitor this metric across all the members in the cluster; a consistently large lag between a single member and its leader indicates that member is slow or unhealthy.\n\nproposals_applied_total records the total number of consensus proposals applied. The etcd server applies every committed proposal asynchronously. The difference between proposals_committed_total and proposals_applied_total should usually be small (within a few thousands even under high load). If the difference between them continues to rise, it indicates that the etcd server is overloaded. This might happen when applying expensive queries like heavy range queries or large txn operations.","fill":1,"gridPos":{"h":7,"w":12,"x":0,"y":35},"id":2,"legend":{"alignAsTable":true,"avg":true,"current":true,"max":true,"min":false,"rightSide":false,"show":true,"total":false,"values":true},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum(increase(etcd_server_proposals_committed_total[5m]))","format":"time_series","intervalFactor":2,"legendFormat":"total number of consensus proposals committed","metric":"","refId":"A","step":60},{"expr":"sum(increase(etcd_server_proposals_applied_total[5m]))","format":"time_series","intervalFactor":2,"legendFormat":"total number of consensus proposals applied","metric":"","refId":"B","step":60}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"The total number of consensus proposals committed","tooltip":{"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"ops","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":"","logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","description":"indicates how many proposals are queued to commit. Rising pending proposals suggests there is a high client load or the member cannot commit proposals.","fill":1,"gridPos":{"h":7,"w":12,"x":12,"y":35},"id":5,"legend":{"avg":false,"current":false,"max":false,"min":false,"show":true,"total":false,"values":false},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum(etcd_server_proposals_pending)","format":"time_series","intervalFactor":2,"legendFormat":"Proposals pending","refId":"A","step":60}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Proposals pending","tooltip":{"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","fill":1,"gridPos":{"h":7,"w":24,"x":0,"y":42},"id":7,"legend":{"avg":false,"current":false,"max":false,"min":false,"show":true,"total":false,"values":false},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum(increase(etcd_disk_wal_fsync_duration_seconds_sum[5m]))","format":"time_series","intervalFactor":2,"legendFormat":" The latency distributions of fsync called by wal","refId":"A","step":30},{"expr":"sum(increase(etcd_disk_backend_commit_duration_seconds_sum[5m]))","format":"time_series","intervalFactor":2,"legendFormat":"The latency distributions of commit called by backend","refId":"B","step":30}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Disks operations","tooltip":{"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","fill":1,"gridPos":{"h":7,"w":24,"x":0,"y":49},"id":8,"legend":{"avg":false,"current":false,"max":false,"min":false,"show":true,"total":false,"values":false},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum(rate(etcd_network_client_grpc_received_bytes_total[5m]))","format":"time_series","intervalFactor":2,"legendFormat":"The total number of bytes received by grpc clients","refId":"A","step":30},{"expr":"sum(rate(etcd_network_client_grpc_sent_bytes_total[5m]))","format":"time_series","intervalFactor":2,"legendFormat":"The total number of bytes sent to grpc clients","refId":"B","step":30}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Network","tooltip":{"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"Bps","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","description":"Abnormally high snapshot duration (snapshot_save_total_duration_seconds) indicates disk issues and might cause the cluster to be unstable.","fill":1,"gridPos":{"h":7,"w":24,"x":0,"y":56},"id":9,"legend":{"avg":false,"current":false,"max":false,"min":false,"show":true,"total":false,"values":false},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum(rate(etcd_debugging_snap_save_total_duration_seconds_sum[5m]))","format":"time_series","intervalFactor":2,"legendFormat":"The total latency distributions of save called by snapshot","refId":"A","step":30}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Snapshot duration","tooltip":{"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}}],"schemaVersion":16,"style":"dark","tags":[],"templating":{"list":[]},"time":{"from":"now-5m","to":"now"},"timepicker":{"refresh_intervals":["5s","10s","30s","1m","5m","15m","30m","1h","2h","1d"],"time_options":["5m","15m","1h","6h","12h","24h","2d","7d","30d"]},"timezone":"browser","title":"Etcd","uid":"8naNKoYik","version":1}
\ No newline at end of file
{"__requires":[{"type":"grafana","id":"grafana","name":"Grafana","version":"5.3.0"},{"type":"panel","id":"graph","name":"Graph","version":"5.0.0"},{"type":"datasource","id":"prometheus","name":"Prometheus","version":"5.0.0"}],"annotations":{"list":[{"builtIn":1,"datasource":"-- Grafana --","enable":true,"hide":true,"iconColor":"rgba(0, 211, 255, 1)","name":"Annotations & Alerts","type":"dashboard"}]},"description":"-","editable":true,"gnetId":5508,"graphTooltip":0,"id":null,"links":[],"panels":[{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","editable":true,"error":false,"fill":1,"grid":{"threshold1Color":"rgba(216, 200, 27, 0.27)","threshold2Color":"rgba(234, 112, 112, 0.22)"},"gridPos":{"h":7,"w":12,"x":0,"y":0},"id":6,"isNew":false,"legend":{"alignAsTable":false,"avg":false,"current":false,"hideEmpty":false,"hideZero":false,"max":false,"min":false,"rightSide":false,"show":true,"total":false,"values":false},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum by(instance) (rate(apiserver_request_count{code!~\"2..\"}[5m]))","format":"time_series","intervalFactor":2,"legendFormat":"Error -{{instance}} ","refId":"A","step":60},{"expr":"sum by(instance) (rate(apiserver_request_count[5m]))","format":"time_series","intervalFactor":2,"legendFormat":"Request - {{instance}}","refId":"B","step":60}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"API Server Request Rates","tooltip":{"msResolution":false,"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"short","logBase":1,"show":true},{"format":"short","logBase":1,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","editable":true,"error":false,"fill":1,"grid":{"threshold1Color":"rgba(216, 200, 27, 0.27)","threshold2Color":"rgba(234, 112, 112, 0.22)"},"gridPos":{"h":7,"w":12,"x":12,"y":0},"id":7,"isNew":false,"legend":{"alignAsTable":false,"avg":false,"current":false,"hideEmpty":false,"hideZero":false,"max":false,"min":false,"rightSide":false,"show":true,"total":false,"values":false},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"avg(apiserver_request_latencies_sum / apiserver_request_latencies_count) by (instance)","format":"time_series","intervalFactor":2,"legendFormat":"","refId":"A","step":30}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"API Server Request Latency","tooltip":{"msResolution":false,"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"ns","logBase":1,"show":true},{"format":"short","logBase":1,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","fill":1,"gridPos":{"h":9,"w":12,"x":0,"y":7},"id":11,"legend":{"avg":false,"current":false,"max":false,"min":false,"show":true,"total":false,"values":false},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"increase(nginx_ingress_controller_nginx_process_requests_total[1m])","format":"time_series","intervalFactor":1,"legendFormat":"Request Rate","refId":"A"}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Nginx Ingress Request Rate","tooltip":{"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","fill":1,"gridPos":{"h":9,"w":12,"x":12,"y":7},"id":9,"legend":{"avg":false,"current":false,"max":false,"min":false,"show":true,"total":false,"values":false},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum(service_depth)","format":"time_series","intervalFactor":1,"legendFormat":"Service Depth","refId":"A"},{"expr":"sum(volumes_depth)","format":"time_series","intervalFactor":1,"legendFormat":"Volumes Depth","refId":"B"},{"expr":"sum(replicationmanager_depth)","format":"time_series","intervalFactor":1,"legendFormat":"Replication Manager Depth","refId":"C"},{"expr":"sum(statefulset_depth)","format":"time_series","intervalFactor":1,"legendFormat":"StatefulSet Depth","refId":"D"},{"expr":"sum(serviceaccount_depth)","format":"time_series","intervalFactor":1,"legendFormat":"Service Account Depth","refId":"E"},{"expr":"sum(endpoint_depth)","format":"time_series","intervalFactor":1,"legendFormat":"Endpoint Depth","refId":"F"},{"expr":"sum(deployment_depth)","format":"time_series","intervalFactor":1,"legendFormat":"Deployment Depth","refId":"G"},{"expr":"sum(daemonset_depth)","format":"time_series","intervalFactor":1,"legendFormat":"DaemonSet Depth","refId":"H"},{"expr":"sum(replicaset_depth)","format":"time_series","intervalFactor":1,"refId":"I"}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Controller Manager Queue Depth","tooltip":{"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}}],"refresh":false,"schemaVersion":16,"style":"dark","tags":[],"templating":{"list":[]},"time":{"from":"now-5m","to":"now"},"timepicker":{"refresh_intervals":["5s","10s","30s","1m","5m","15m","30m","1h","2h","1d"],"time_options":["5m","15m","1h","6h","12h","24h","2d","7d","30d"]},"timezone":"browser","title":"Kubernetes Components","uid":"Ld4acTYmz","version":1}
\ No newline at end of file
{"__requires":[{"id":"grafana","name":"Grafana","type":"grafana","version":"5.3.0"},{"id":"graph","name":"Graph","type":"panel","version":"5.0.0"},{"id":"prometheus","name":"Prometheus","type":"datasource","version":"5.0.0"},{"id":"singlestat","name":"Singlestat","type":"panel","version":"5.0.0"}],"annotations":{"list":[{"builtIn":1,"datasource":"-- Grafana --","enable":true,"hide":true,"iconColor":"rgba(0, 211, 255, 1)","name":"Annotations & Alerts","type":"dashboard"}]},"editable":true,"gnetId":null,"graphTooltip":0,"id":null,"links":[],"panels":[{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","description":"This represents the total [CPU resource requests](https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/#meaning-of-cpu) in the cluster.\nFor comparison the total [allocatable CPU cores](https://github.com/kubernetes/community/blob/master/contributors/design-proposals/node-allocatable.md) is also shown.","editable":true,"error":false,"fill":1,"grid":{"threshold1Color":"rgba(216, 200, 27, 0.27)","threshold2Color":"rgba(234, 112, 112, 0.22)"},"gridPos":{"h":8,"w":18,"x":0,"y":0},"id":1,"isNew":false,"legend":{"alignAsTable":false,"avg":false,"current":false,"hideEmpty":false,"hideZero":false,"max":false,"min":false,"rightSide":false,"show":true,"total":false,"values":false},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"min(sum(kube_node_status_allocatable_cpu_cores) by (instance))","hide":false,"intervalFactor":2,"legendFormat":"allocatable","refId":"A","step":20},{"expr":"max(sum(kube_pod_container_resource_requests_cpu_cores) by (instance))","hide":false,"intervalFactor":2,"legendFormat":"requested","refId":"B","step":20}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"CPU Cores","tooltip":{"msResolution":false,"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"short","label":"CPU Cores","logBase":1,"show":true},{"format":"short","logBase":1,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(50, 172, 45, 0.97)","rgba(237, 129, 40, 0.89)","rgba(245, 54, 54, 0.9)"],"datasource":"RANCHER_MONITORING","editable":true,"format":"percent","gauge":{"maxValue":100,"minValue":0,"show":true,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":8,"w":6,"x":18,"y":0},"hideTimeOverride":false,"id":2,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"max(sum(kube_pod_container_resource_requests_cpu_cores) by (instance)) / min(sum(kube_node_status_allocatable_cpu_cores) by (instance)) * 100","intervalFactor":2,"legendFormat":"","refId":"A","step":240}],"thresholds":"80, 90","title":"CPU Cores","transparent":false,"type":"singlestat","valueFontSize":"110%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"avg"},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","description":"This represents the total [memory resource requests](https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/#meaning-of-memory) in the cluster.\nFor comparison the total [allocatable memory](https://github.com/kubernetes/community/blob/master/contributors/design-proposals/node-allocatable.md) is also shown.","editable":true,"error":false,"fill":1,"grid":{"threshold1Color":"rgba(216, 200, 27, 0.27)","threshold2Color":"rgba(234, 112, 112, 0.22)"},"gridPos":{"h":8,"w":18,"x":0,"y":8},"id":3,"isNew":false,"legend":{"alignAsTable":false,"avg":false,"current":false,"hideEmpty":false,"hideZero":false,"max":false,"min":false,"rightSide":false,"show":true,"total":false,"values":false},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"min(sum(kube_node_status_allocatable_memory_bytes) by (instance))","hide":false,"intervalFactor":2,"legendFormat":"allocatable","refId":"A","step":20},{"expr":"max(sum(kube_pod_container_resource_requests_memory_bytes) by (instance))","hide":false,"intervalFactor":2,"legendFormat":"requested","refId":"B","step":20}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Memory","tooltip":{"msResolution":false,"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"bytes","label":"Memory","logBase":1,"show":true},{"format":"short","logBase":1,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(50, 172, 45, 0.97)","rgba(237, 129, 40, 0.89)","rgba(245, 54, 54, 0.9)"],"datasource":"RANCHER_MONITORING","editable":true,"format":"percent","gauge":{"maxValue":100,"minValue":0,"show":true,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":8,"w":6,"x":18,"y":8},"hideTimeOverride":false,"id":4,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"max(sum(kube_pod_container_resource_requests_memory_bytes) by (instance)) / min(sum(kube_node_status_allocatable_memory_bytes) by (instance)) * 100","intervalFactor":2,"legendFormat":"","refId":"A","step":240}],"thresholds":"80, 90","title":"Memory","transparent":false,"type":"singlestat","valueFontSize":"110%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"avg"}],"refresh":false,"schemaVersion":16,"style":"dark","tags":[],"templating":{"list":[]},"time":{"from":"now-5m","to":"now"},"timepicker":{"refresh_intervals":["5s","10s","30s","1m","5m","15m","30m","1h","2h","1d"],"time_options":["5m","15m","1h","6h","12h","24h","2d","7d","30d"]},"timezone":"browser","title":"Kubernetes Resource Requests","uid":"0MdTILxik","version":1}
\ No newline at end of file
This source diff could not be displayed because it is too large. You can view the blob instead.
{"__requires":[{"type":"grafana","id":"grafana","name":"Grafana","version":"5.3.0"},{"type":"panel","id":"graph","name":"Graph","version":"5.0.0"},{"type":"datasource","id":"prometheus","name":"Prometheus","version":"5.0.0"},{"type":"panel","id":"singlestat","name":"Singlestat","version":"5.0.0"}],"annotations":{"list":[{"builtIn":1,"datasource":"-- Grafana --","enable":true,"hide":true,"iconColor":"rgba(0, 211, 255, 1)","name":"Annotations & Alerts","type":"dashboard"}]},"description":"This is a simple dashboard for: https://github.com/banzaicloud/logging-operator utilising Fluent-bit and Fluentd","editable":true,"gnetId":7668,"graphTooltip":0,"id":null,"links":[],"panels":[{"cacheTimeout":null,"colorBackground":false,"colorValue":true,"colors":["#d44a3a","rgba(237, 129, 40, 0.89)","#299c46"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":5,"w":3,"x":0,"y":0},"id":4,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"sum(kube_node_status_condition{condition=\"Ready\"})","format":"time_series","intervalFactor":1,"legendFormat":"","refId":"A"}],"thresholds":"0,1","title":"Active Nodes","type":"singlestat","valueFontSize":"100%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":true,"colors":["#d44a3a","rgba(237, 129, 40, 0.89)","#299c46"],"datasource":"RANCHER_MONITORING","format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":5,"w":3,"x":3,"y":0},"id":8,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"sum(kube_pod_info{pod=~\"fluentd.*\"})","format":"time_series","instant":false,"intervalFactor":1,"refId":"A"}],"thresholds":"0,1","title":"Fluentd","type":"singlestat","valueFontSize":"100%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","fill":1,"gridPos":{"h":5,"w":9,"x":6,"y":0},"id":2,"legend":{"alignAsTable":true,"avg":false,"current":true,"max":false,"min":false,"rightSide":true,"show":true,"sort":"current","sortDesc":true,"total":false,"values":true},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum(rate(fluentd_input_status_num_records_total[1m]))by (instance)","format":"time_series","hide":false,"intervalFactor":1,"legendFormat":"{{ instance }}","refId":"A"}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Fluent input records","tooltip":{"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"bytes","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","fill":1,"gridPos":{"h":5,"w":9,"x":15,"y":0},"id":9,"legend":{"alignAsTable":true,"avg":false,"current":true,"max":false,"min":false,"rightSide":true,"show":true,"sort":"current","sortDesc":true,"total":false,"values":true},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"rate(fluentd_output_status_buffer_queue_length[1m])","format":"time_series","hide":false,"intervalFactor":1,"legendFormat":"{{ type }}","refId":"A"}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Fluentd output buffer queue length","tooltip":{"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"bytes","label":null,"logBase":1,"max":null,"min":null,"show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","fill":1,"gridPos":{"h":5,"w":8,"x":0,"y":5},"id":10,"legend":{"alignAsTable":true,"avg":false,"current":true,"max":false,"min":false,"rightSide":true,"show":true,"sort":"current","sortDesc":true,"total":false,"values":true},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"rate(fluentd_output_status_num_errors[1m])","format":"time_series","hide":false,"intervalFactor":1,"legendFormat":"{{ type }}","refId":"A"}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Fluentd output error/s","tooltip":{"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"bytes","label":null,"logBase":1,"max":null,"min":"0","show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","fill":1,"gridPos":{"h":5,"w":8,"x":8,"y":5},"id":12,"legend":{"alignAsTable":true,"avg":false,"current":true,"max":false,"min":false,"rightSide":true,"show":true,"sort":"current","sortDesc":true,"total":false,"values":true},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"rate(fluentd_output_status_emit_count[1m])","format":"time_series","hide":false,"intervalFactor":1,"legendFormat":"{{ type }}","refId":"A"}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Fluentd output emit/s by Plugin","tooltip":{"shared":true,"sort":2,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"ops","label":null,"logBase":1,"max":null,"min":"0","show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","fill":1,"gridPos":{"h":5,"w":8,"x":16,"y":5},"id":15,"legend":{"alignAsTable":true,"avg":false,"current":true,"max":false,"min":false,"rightSide":true,"show":true,"sort":"current","sortDesc":true,"total":false,"values":true},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"fluentd_output_status_buffer_queue_length","format":"time_series","hide":false,"intervalFactor":1,"legendFormat":"{{ type }}","refId":"A"}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Fluentd output buffer queue","tooltip":{"shared":true,"sort":2,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"short","label":null,"logBase":1,"max":null,"min":"0","show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","fill":1,"gridPos":{"h":6,"w":8,"x":0,"y":10},"id":11,"legend":{"alignAsTable":true,"avg":false,"current":true,"max":false,"min":false,"rightSide":true,"show":true,"sort":"current","sortDesc":true,"total":false,"values":true},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"rate(fluentd_output_status_retry_count[1m])","format":"time_series","hide":false,"intervalFactor":1,"legendFormat":"Retries {{ type }}","refId":"A"},{"expr":"rate(fluentd_output_status_rollback_count[1m])","format":"time_series","intervalFactor":1,"legendFormat":"Rollback {{ type }}","refId":"B"}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Fluentd retries/rollback","tooltip":{"shared":true,"sort":0,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"decimals":null,"format":"short","label":"","logBase":1,"max":null,"min":"0","show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":"0","show":false}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","fill":1,"gridPos":{"h":6,"w":8,"x":8,"y":10},"id":14,"legend":{"alignAsTable":false,"avg":false,"current":true,"max":true,"min":true,"rightSide":false,"show":true,"sort":"current","sortDesc":true,"total":false,"values":true},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum(rate(fluentd_output_status_retry_count[1m]))","format":"time_series","hide":false,"intervalFactor":1,"legendFormat":"Retry rate","refId":"A"},{"expr":"sum(rate(fluentd_output_status_num_errors[1m]))","format":"time_series","intervalFactor":1,"legendFormat":"Error rate","refId":"C"}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Fluentd output error/retry rate","tooltip":{"shared":true,"sort":2,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"ops","label":null,"logBase":1,"max":null,"min":"0","show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","fill":1,"gridPos":{"h":6,"w":8,"x":16,"y":10},"id":13,"legend":{"alignAsTable":false,"avg":false,"current":true,"max":true,"min":true,"rightSide":false,"show":true,"sort":"current","sortDesc":true,"total":false,"values":true},"lines":true,"linewidth":1,"links":[],"nullPointMode":"null","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"fluentd_output_status_buffer_total_bytes","format":"time_series","hide":false,"intervalFactor":1,"legendFormat":"{{ type }}","refId":"A"}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Fluentd output buffer size","tooltip":{"shared":true,"sort":2,"value_type":"individual"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"bytes","label":null,"logBase":1,"max":null,"min":"0","show":true},{"format":"short","label":null,"logBase":1,"max":null,"min":null,"show":true}],"yaxis":{"align":false,"alignLevel":null}}],"refresh":"30s","schemaVersion":16,"style":"dark","tags":[],"templating":{"list":[]},"time":{"from":"now-5m","to":"now"},"timepicker":{"refresh_intervals":["5s","10s","30s","1m","5m","15m","30m","1h","2h","1d"],"time_options":["5m","15m","1h","6h","12h","24h","2d","7d","30d"]},"timezone":"","title":"Rancher Components","uid":"bNn5LUtiz","version":1}
\ No newline at end of file
{"__requires":[{"id":"grafana","name":"Grafana","type":"grafana","version":"5.3.0"},{"id":"graph","name":"Graph","type":"panel","version":"5.0.0"},{"id":"prometheus","name":"Prometheus","type":"datasource","version":"5.0.0"},{"id":"singlestat","name":"Singlestat","type":"panel","version":"5.0.0"}],"annotations":{"list":[{"builtIn":1,"datasource":"-- Grafana --","enable":true,"hide":true,"iconColor":"rgba(0, 211, 255, 1)","name":"Annotations & Alerts","type":"dashboard"}]},"description":"Kubernetes DaemonSet Overview","editable":true,"gnetId":6615,"graphTooltip":1,"id":null,"iteration":1543396055929,"links":[],"panels":[{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","decimals":null,"editable":true,"format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":false},"gridPos":{"h":3,"w":8,"x":0,"y":0},"id":5,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"max(kube_daemonset_status_desired_number_scheduled{daemonset=\"$daemonset_name\",namespace=\"$daemonset_namespace\"}) without (instance, pod)","format":"time_series","instant":false,"interval":"","intervalFactor":2,"legendFormat":"","refId":"A","step":600}],"thresholds":"","title":"Desired Replicas","transparent":false,"type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"N/A","value":"null"}],"valueName":"avg"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","editable":true,"format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":8,"x":8,"y":0},"id":6,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"min(kube_daemonset_status_number_available{daemonset=\"$daemonset_name\",namespace=\"$daemonset_namespace\"}) without (instance, pod)","format":"time_series","intervalFactor":2,"refId":"A","step":600}],"thresholds":"","title":"Available Replicas","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"N/A","value":"null"}],"valueName":"avg"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","editable":true,"format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":8,"x":16,"y":0},"id":2,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"max(kube_daemonset_metadata_generation{daemonset=\"$daemonset_name\",namespace=\"$daemonset_namespace\"}) without (instance, pod)","format":"time_series","intervalFactor":2,"refId":"A","step":600}],"thresholds":"","title":"Metadata Generation","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"N/A","value":"null"}],"valueName":"avg"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["#299c46","rgba(237, 129, 40, 0.89)","#d44a3a"],"datasource":"RANCHER_MONITORING","decimals":2,"format":"s","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":6,"w":3,"x":0,"y":3},"id":11,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"time() - max(kube_daemonset_created{namespace=\"$daemonset_namespace\",daemonset=\"$daemonset_name\"})","format":"time_series","intervalFactor":1,"refId":"A"}],"thresholds":"","title":"DaemonSet Create Time","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"N/A","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","editable":true,"format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":6,"w":7,"x":3,"y":3},"id":8,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"cores","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"sum(rate(container_cpu_usage_seconds_total{namespace=\"$daemonset_namespace\",pod_name=~\"$daemonset_name.*\"}[5m]))","format":"time_series","intervalFactor":2,"refId":"A","step":600}],"thresholds":"","title":"CPU","type":"singlestat","valueFontSize":"110%","valueMaps":[{"op":"=","text":"N/A","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","editable":true,"format":"bytes","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":6,"w":7,"x":10,"y":3},"id":9,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"80%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"sum(container_memory_working_set_bytes{namespace=\"$daemonset_namespace\",pod_name=~\"$daemonset_name.*\", container_name!=\"\"})","format":"time_series","intervalFactor":2,"refId":"A","step":600}],"thresholds":"","title":"Memory","type":"singlestat","valueFontSize":"110%","valueMaps":[{"op":"=","text":"N/A","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","editable":true,"format":"Bps","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":false},"gridPos":{"h":6,"w":7,"x":17,"y":3},"id":7,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"sum(rate(container_network_transmit_bytes_total{namespace=\"$daemonset_namespace\",pod_name=~\"$daemonset_name.*\"}[5m])) + sum(rate(container_network_receive_bytes_total{namespace=\"$daemonset_namespace\",pod_name=~\"$daemonset_name.*\"}[5m]))","format":"time_series","intervalFactor":2,"refId":"A","step":600}],"thresholds":"","title":"Network","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"N/A","value":"null"}],"valueName":"current"},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","editable":true,"error":false,"fill":1,"grid":{"threshold1Color":"rgba(216, 200, 27, 0.27)","threshold2Color":"rgba(234, 112, 112, 0.22)"},"gridPos":{"h":7,"w":12,"x":0,"y":9},"id":13,"isNew":false,"legend":{"alignAsTable":false,"avg":false,"current":true,"hideEmpty":false,"hideZero":false,"max":false,"min":false,"rightSide":false,"show":false,"total":false,"values":true},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum by (pod_name) (rate(container_cpu_usage_seconds_total{namespace=\"$daemonset_namespace\",pod_name=~\"$daemonset_name.*\"}[5m]))","format":"time_series","intervalFactor":2,"legendFormat":"{{pod_name}}","refId":"A","step":30}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"CPU Usage","tooltip":{"msResolution":true,"shared":true,"sort":0,"value_type":"cumulative"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"decimals":null,"format":"percentunit","label":"","logBase":1,"min":"0","show":true},{"format":"short","logBase":1,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","editable":true,"error":false,"fill":1,"grid":{"threshold1Color":"rgba(216, 200, 27, 0.27)","threshold2Color":"rgba(234, 112, 112, 0.22)"},"gridPos":{"h":7,"w":12,"x":12,"y":9},"id":15,"isNew":false,"legend":{"alignAsTable":false,"avg":false,"current":false,"hideEmpty":false,"hideZero":false,"max":false,"min":false,"rightSide":false,"show":false,"total":false,"values":false},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum by (pod_name) (container_memory_working_set_bytes{namespace=\"$daemonset_namespace\",pod_name=~\"$daemonset_name.*\", container_name!=\"POD\"})","format":"time_series","interval":"10s","intervalFactor":1,"legendFormat":"{{ pod_name }}","refId":"A","step":15}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Memory Usage","tooltip":{"msResolution":true,"shared":true,"sort":0,"value_type":"cumulative"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"bytes","logBase":1,"max":null,"min":"0","show":true},{"format":"short","logBase":1,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","decimals":0,"editable":true,"error":false,"fill":1,"grid":{"threshold1Color":"rgba(216, 200, 27, 0.27)","threshold2Color":"rgba(234, 112, 112, 0.22)"},"gridPos":{"h":9,"w":24,"x":0,"y":16},"id":1,"isNew":true,"legend":{"alignAsTable":true,"avg":false,"current":true,"hideEmpty":false,"hideZero":false,"max":false,"min":false,"rightSide":true,"show":true,"total":false,"values":true},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"avg(kube_daemonset_status_number_ready{daemonset=\"$daemonset_name\",namespace=\"$daemonset_namespace\"}) without (instance, pod)","format":"time_series","intervalFactor":1,"legendFormat":"Ready","refId":"A"},{"expr":"avg(kube_daemonset_status_number_available{daemonset=\"$daemonset_name\",namespace=\"$daemonset_namespace\"}) without (instance, pod)","format":"time_series","hide":false,"intervalFactor":1,"legendFormat":"Available","refId":"C"},{"expr":"avg(kube_daemonset_status_number_unavailable{daemonset=\"$daemonset_name\",namespace=\"$daemonset_namespace\"}) without (instance, pod)","format":"time_series","hide":false,"intervalFactor":1,"legendFormat":"Unavailable","refId":"B"},{"expr":"avg(kube_daemonset_status_number_misscheduled{daemonset=\"$daemonset_name\",namespace=\"$daemonset_namespace\"}) without (instance, pod)","format":"time_series","hide":false,"intervalFactor":1,"legendFormat":"Misscheduled","refId":"D"}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Replicas Status","tooltip":{"msResolution":true,"shared":true,"sort":0,"value_type":"cumulative"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"decimals":0,"format":"none","label":"","logBase":1,"show":true},{"format":"short","label":"","logBase":1,"show":false}],"yaxis":{"align":false,"alignLevel":null}}],"refresh":"30s","schemaVersion":16,"style":"dark","tags":[],"templating":{"list":[{"allValue":"","current":{},"datasource":"RANCHER_MONITORING","hide":0,"includeAll":false,"label":"Namespace","multi":false,"name":"daemonset_namespace","options":[],"query":"label_values(kube_daemonset_metadata_generation, namespace)","refresh":1,"regex":"","skipUrlSync":false,"sort":0,"tagValuesQuery":null,"tags":[],"tagsQuery":"","type":"query","useTags":false},{"allValue":"","current":{},"datasource":"RANCHER_MONITORING","hide":0,"includeAll":false,"label":"DaemonSet","multi":false,"name":"daemonset_name","options":[],"query":"label_values(kube_daemonset_metadata_generation{namespace=\"$daemonset_namespace\"}, daemonset)","refresh":1,"regex":"","skipUrlSync":false,"sort":0,"tagValuesQuery":"","tags":[],"tagsQuery":"","type":"query","useTags":false}]},"time":{"from":"now-5m","to":"now"},"timepicker":{"hidden":false,"refresh_intervals":["5s","10s","30s","1m","5m","15m","30m","1h","2h","1d"],"time_options":["5m","15m","1h","6h","12h","24h","2d","7d","30d"]},"timezone":"browser","title":"DaemonSet","uid":"gekRLzHiz","version":1}
\ No newline at end of file
{"__requires":[{"id":"grafana","name":"Grafana","type":"grafana","version":"5.3.0"},{"id":"graph","name":"Graph","type":"panel","version":"5.0.0"},{"id":"prometheus","name":"Prometheus","type":"datasource","version":"5.0.0"},{"id":"singlestat","name":"Singlestat","type":"panel","version":"5.0.0"}],"annotations":{"list":[{"builtIn":1,"datasource":"-- Grafana --","enable":true,"hide":true,"iconColor":"rgba(0, 211, 255, 1)","name":"Annotations & Alerts","type":"dashboard"}]},"editable":true,"gnetId":null,"graphTooltip":1,"id":null,"iteration":1543396071820,"links":[],"panels":[{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","editable":true,"format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":5,"w":8,"x":0,"y":0},"id":8,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"cores","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"sum(rate(container_cpu_usage_seconds_total{namespace=\"$deployment_namespace\",pod_name=~\"$deployment_name.*\"}[5m]))","intervalFactor":2,"refId":"A","step":600}],"thresholds":"","title":"CPU","type":"singlestat","valueFontSize":"110%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"avg"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","editable":true,"format":"decbytes","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":5,"w":8,"x":8,"y":0},"id":9,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"80%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"sum(container_memory_working_set_bytes{namespace=\"$deployment_namespace\",pod_name=~\"$deployment_name.*\",container_name!=\"\"})","intervalFactor":2,"refId":"A","step":600}],"thresholds":"","title":"Memory","type":"singlestat","valueFontSize":"110%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"avg"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","editable":true,"format":"Bps","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":false},"gridPos":{"h":5,"w":8,"x":16,"y":0},"id":7,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"sum(rate(container_network_transmit_bytes_total{namespace=\"$deployment_namespace\",pod_name=~\"$deployment_name.*\"}[5m])) + sum(rate(container_network_receive_bytes_total{namespace=\"$deployment_namespace\",pod_name=~\"$deployment_name.*\"}[5m]))","intervalFactor":2,"refId":"A","step":600}],"thresholds":"","title":"Network","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"avg"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","editable":true,"format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":false},"gridPos":{"h":3,"w":6,"x":0,"y":5},"id":5,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"max(kube_deployment_spec_replicas{deployment=\"$deployment_name\",namespace=\"$deployment_namespace\"}) without (instance, pod)","intervalFactor":2,"metric":"kube_deployment_spec_replicas","refId":"A","step":600}],"thresholds":"","title":"Desired Replicas","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"avg"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","editable":true,"format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":6,"x":6,"y":5},"id":6,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"min(kube_deployment_status_replicas_available{deployment=\"$deployment_name\",namespace=\"$deployment_namespace\"}) without (instance, pod)","intervalFactor":2,"refId":"A","step":600}],"thresholds":"","title":"Available Replicas","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"avg"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","editable":true,"format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":6,"x":12,"y":5},"id":3,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"max(kube_deployment_status_observed_generation{deployment=\"$deployment_name\",namespace=\"$deployment_namespace\"}) without (instance, pod)","intervalFactor":2,"refId":"A","step":600}],"thresholds":"","title":"Observed Generation","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"avg"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","editable":true,"format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":6,"x":18,"y":5},"id":2,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"max(kube_deployment_metadata_generation{deployment=\"$deployment_name\",namespace=\"$deployment_namespace\"}) without (instance, pod)","intervalFactor":2,"refId":"A","step":600}],"thresholds":"","title":"Metadata Generation","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"avg"},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","editable":true,"error":false,"fill":1,"grid":{"threshold1Color":"rgba(216, 200, 27, 0.27)","threshold2Color":"rgba(234, 112, 112, 0.22)"},"gridPos":{"h":9,"w":24,"x":0,"y":8},"id":1,"isNew":true,"legend":{"alignAsTable":false,"avg":false,"current":false,"hideEmpty":false,"hideZero":false,"max":false,"min":false,"rightSide":false,"show":true,"total":false,"values":false},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"max(kube_deployment_status_replicas{deployment=\"$deployment_name\",namespace=\"$deployment_namespace\"}) without (instance, pod)","intervalFactor":2,"legendFormat":"Current","refId":"A","step":30},{"expr":"min(kube_deployment_status_replicas_available{deployment=\"$deployment_name\",namespace=\"$deployment_namespace\"}) without (instance, pod)","intervalFactor":2,"legendFormat":"Available","refId":"B","step":30},{"expr":"max(kube_deployment_status_replicas_unavailable{deployment=\"$deployment_name\",namespace=\"$deployment_namespace\"}) without (instance, pod)","intervalFactor":2,"legendFormat":"Unavailable","refId":"C","step":30},{"expr":"min(kube_deployment_status_replicas_updated{deployment=\"$deployment_name\",namespace=\"$deployment_namespace\"}) without (instance, pod)","intervalFactor":2,"legendFormat":"Updated","refId":"D","step":30},{"expr":"max(kube_deployment_spec_replicas{deployment=\"$deployment_name\",namespace=\"$deployment_namespace\"}) without (instance, pod)","intervalFactor":2,"legendFormat":"Desired","refId":"E","step":30}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Replicas","tooltip":{"msResolution":true,"shared":true,"sort":0,"value_type":"cumulative"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"none","label":"","logBase":1,"show":true},{"format":"short","label":"","logBase":1,"show":false}],"yaxis":{"align":false,"alignLevel":null}}],"schemaVersion":16,"style":"dark","tags":[],"templating":{"list":[{"allValue":"","current":{},"datasource":"RANCHER_MONITORING","hide":0,"includeAll":false,"label":"Namespace","multi":false,"name":"deployment_namespace","options":[],"query":"label_values(kube_deployment_metadata_generation, namespace)","refresh":1,"regex":"","skipUrlSync":false,"sort":0,"tagValuesQuery":null,"tags":[],"tagsQuery":"","type":"query","useTags":false},{"allValue":"","current":{},"datasource":"RANCHER_MONITORING","hide":0,"includeAll":false,"label":"Deployment","multi":false,"name":"deployment_name","options":[],"query":"label_values(kube_deployment_metadata_generation{namespace=\"$deployment_namespace\"}, deployment)","refresh":1,"regex":"","skipUrlSync":false,"sort":0,"tagValuesQuery":"","tags":[],"tagsQuery":"deployment","type":"query","useTags":false}]},"time":{"from":"now-5m","to":"now"},"timepicker":{"refresh_intervals":["5s","10s","30s","1m","5m","15m","30m","1h","2h","1d"],"time_options":["5m","15m","1h","6h","12h","24h","2d","7d","30d"]},"timezone":"browser","title":"Deployment","uid":"kZdoIYxik","version":1}
\ No newline at end of file
{"__requires":[{"id":"grafana","name":"Grafana","type":"grafana","version":"5.3.0"},{"id":"graph","name":"Graph","type":"panel","version":"5.0.0"},{"id":"prometheus","name":"Prometheus","type":"datasource","version":"5.0.0"}],"annotations":{"list":[{"builtIn":1,"datasource":"-- Grafana --","enable":true,"hide":true,"iconColor":"rgba(0, 211, 255, 1)","name":"Annotations & Alerts","type":"dashboard"}]},"editable":true,"gnetId":null,"graphTooltip":1,"id":null,"iteration":1543396157762,"links":[],"panels":[{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","editable":true,"error":false,"fill":1,"grid":{"threshold1Color":"rgba(216, 200, 27, 0.27)","threshold2Color":"rgba(234, 112, 112, 0.22)"},"gridPos":{"h":7,"w":24,"x":0,"y":0},"id":1,"isNew":false,"legend":{"alignAsTable":true,"avg":true,"current":true,"hideEmpty":false,"hideZero":false,"max":false,"min":false,"rightSide":true,"show":true,"total":false,"values":true},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum by(container_name) (container_memory_working_set_bytes{namespace=\"$namespace\",image!=\"\",container_name=~\"$container\",container_name!=\"POD\",pod_name=\"$pod\"})","interval":"10s","intervalFactor":1,"legendFormat":"Current: {{ container_name }}","metric":"container_memory_working_set_bytes","refId":"A","step":15},{"expr":"kube_pod_container_resource_requests_memory_bytes{namespace=\"$namespace\",pod=\"$pod\",container=~\"$container\"}","interval":"10s","intervalFactor":2,"legendFormat":"Requested: {{ container }}","metric":"kube_pod_container_resource_requests_memory_bytes","refId":"B","step":20},{"expr":"kube_pod_container_resource_limits_memory_bytes{namespace=\"$namespace\",pod=\"$pod\",container=~\"$container\"}","interval":"10s","intervalFactor":2,"legendFormat":"Limit: {{ container }}","metric":"kube_pod_container_resource_limits_memory_bytes","refId":"C","step":20}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Memory Usage","tooltip":{"msResolution":true,"shared":true,"sort":0,"value_type":"cumulative"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"bytes","logBase":1,"show":true},{"format":"short","logBase":1,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","editable":true,"error":false,"fill":1,"grid":{"threshold1Color":"rgba(216, 200, 27, 0.27)","threshold2Color":"rgba(234, 112, 112, 0.22)"},"gridPos":{"h":7,"w":24,"x":0,"y":7},"id":2,"isNew":false,"legend":{"alignAsTable":true,"avg":true,"current":true,"hideEmpty":false,"hideZero":false,"max":false,"min":false,"rightSide":true,"show":true,"total":false,"values":true},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sum by (container_name)(rate(container_cpu_usage_seconds_total{namespace=\"$namespace\",image!=\"\",container_name=~\"$container\",container_name!=\"POD\",pod_name=\"$pod\"}[5m]))","intervalFactor":2,"legendFormat":"Current: {{ container_name }}","refId":"A","step":30},{"expr":"kube_pod_container_resource_requests_cpu_cores{namespace=\"$namespace\",pod=\"$pod\",container=~\"$container\"}","interval":"10s","intervalFactor":2,"legendFormat":"Requested: {{ container }}","metric":"kube_pod_container_resource_requests_cpu_cores","refId":"B","step":20},{"expr":"kube_pod_container_resource_limits_cpu_cores{namespace=\"$namespace\",pod=\"$pod\",container=~\"$container\"}","interval":"10s","intervalFactor":2,"legendFormat":"Limit: {{ container }}","metric":"kube_pod_container_resource_limits_memory_bytes","refId":"C","step":20}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"CPU Usage","tooltip":{"msResolution":true,"shared":true,"sort":0,"value_type":"cumulative"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"percentunit","logBase":1,"show":true},{"format":"short","logBase":1,"show":true}],"yaxis":{"align":false,"alignLevel":null}},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","editable":true,"error":false,"fill":1,"grid":{"threshold1Color":"rgba(216, 200, 27, 0.27)","threshold2Color":"rgba(234, 112, 112, 0.22)"},"gridPos":{"h":7,"w":24,"x":0,"y":14},"id":3,"isNew":false,"legend":{"alignAsTable":true,"avg":true,"current":true,"hideEmpty":false,"hideZero":false,"max":false,"min":false,"rightSide":true,"show":true,"total":false,"values":true},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"sort_desc(sum by (pod_name) (rate(container_network_receive_bytes_total{namespace=\"$namespace\",pod_name=\"$pod\"}[5m])))","intervalFactor":2,"legendFormat":"{{ pod_name }}","refId":"A","step":30}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Network I/O","tooltip":{"msResolution":true,"shared":true,"sort":0,"value_type":"cumulative"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"bytes","logBase":1,"show":true},{"format":"short","logBase":1,"show":true}],"yaxis":{"align":false,"alignLevel":null}}],"refresh":false,"schemaVersion":16,"style":"dark","tags":[],"templating":{"list":[{"allValue":"","current":{},"datasource":"RANCHER_MONITORING","hide":0,"includeAll":false,"label":"Namespace","multi":false,"name":"namespace","options":[],"query":"label_values(kube_pod_info, namespace)","refresh":1,"regex":"","skipUrlSync":false,"sort":0,"tagValuesQuery":"","tags":[],"tagsQuery":"","type":"query","useTags":false},{"allValue":"","current":{},"datasource":"RANCHER_MONITORING","hide":0,"includeAll":false,"label":"Pod","multi":false,"name":"pod","options":[],"query":"label_values(kube_pod_info{namespace=\"$namespace\"}, pod)","refresh":1,"regex":"","skipUrlSync":false,"sort":0,"tagValuesQuery":"","tags":[],"tagsQuery":"","type":"query","useTags":false},{"allValue":".*","current":{},"datasource":"RANCHER_MONITORING","hide":0,"includeAll":true,"label":"Container","multi":false,"name":"container","options":[],"query":"label_values(kube_pod_container_info{namespace=\"$namespace\", pod=\"$pod\"}, container)","refresh":1,"regex":"","skipUrlSync":false,"sort":0,"tagValuesQuery":"","tags":[],"tagsQuery":"","type":"query","useTags":false}]},"time":{"from":"now-5m","to":"now"},"timepicker":{"refresh_intervals":["5s","10s","30s","1m","5m","15m","30m","1h","2h","1d"],"time_options":["5m","15m","1h","6h","12h","24h","2d","7d","30d"]},"timezone":"browser","title":"Pods","uid":"XSOTSYxiz","version":1}
\ No newline at end of file
{"__requires":[{"id":"grafana","name":"Grafana","type":"grafana","version":"5.3.0"},{"id":"graph","name":"Graph","type":"panel","version":"5.0.0"},{"id":"prometheus","name":"Prometheus","type":"datasource","version":"5.0.0"},{"id":"singlestat","name":"Singlestat","type":"panel","version":"5.0.0"}],"annotations":{"list":[{"builtIn":1,"datasource":"-- Grafana --","enable":true,"hide":true,"iconColor":"rgba(0, 211, 255, 1)","name":"Annotations & Alerts","type":"dashboard"}]},"editable":true,"gnetId":null,"graphTooltip":1,"id":null,"iteration":1543396179999,"links":[],"panels":[{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","editable":true,"format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":5,"w":8,"x":0,"y":0},"id":8,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"cores","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"sum(rate(container_cpu_usage_seconds_total{namespace=\"$statefulset_namespace\",pod_name=~\"$statefulset_name.*\"}[5m]))","intervalFactor":2,"refId":"A","step":600}],"thresholds":"","title":"CPU","type":"singlestat","valueFontSize":"110%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"avg"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","editable":true,"format":"bytes","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":5,"w":8,"x":8,"y":0},"id":9,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"80%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"sum(container_memory_working_set_bytes{namespace=\"$statefulset_namespace\",pod_name=~\"$statefulset_name.*\",container_name!=\"\"})","intervalFactor":2,"refId":"A","step":600}],"thresholds":"","title":"Memory","type":"singlestat","valueFontSize":"110%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"current"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","editable":true,"format":"Bps","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":false},"gridPos":{"h":5,"w":8,"x":16,"y":0},"id":7,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":true},"tableColumn":"","targets":[{"expr":"sum(rate(container_network_transmit_bytes_total{namespace=\"$statefulset_namespace\",pod_name=~\"$statefulset_name.*\"}[5m])) + sum(rate(container_network_receive_bytes_total{namespace=\"$statefulset_namespace\",pod_name=~\"$statefulset_name.*\"}[5m]))","intervalFactor":2,"refId":"A","step":600}],"thresholds":"","title":"Network","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"avg"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","editable":true,"format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":false},"gridPos":{"h":3,"w":6,"x":0,"y":5},"id":5,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"max(kube_statefulset_replicas{statefulset=\"$statefulset_name\",namespace=\"$statefulset_namespace\"}) without (instance, pod)","intervalFactor":2,"metric":"kube_statefulset_replicas","refId":"A","step":600}],"thresholds":"","title":"Desired Replicas","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"avg"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","editable":true,"format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":6,"x":6,"y":5},"id":6,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"min(kube_statefulset_status_replicas{statefulset=\"$statefulset_name\",namespace=\"$statefulset_namespace\"}) without (instance, pod)","intervalFactor":2,"refId":"A","step":600}],"thresholds":"","title":"Available Replicas","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"avg"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","editable":true,"format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":6,"x":12,"y":5},"id":3,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"max(kube_statefulset_status_observed_generation{statefulset=\"$statefulset_name\",namespace=\"$statefulset_namespace\"}) without (instance, pod)","intervalFactor":2,"refId":"A","step":600}],"thresholds":"","title":"Observed Generation","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"avg"},{"cacheTimeout":null,"colorBackground":false,"colorValue":false,"colors":["rgba(245, 54, 54, 0.9)","rgba(237, 129, 40, 0.89)","rgba(50, 172, 45, 0.97)"],"datasource":"RANCHER_MONITORING","editable":true,"format":"none","gauge":{"maxValue":100,"minValue":0,"show":false,"thresholdLabels":false,"thresholdMarkers":true},"gridPos":{"h":3,"w":6,"x":18,"y":5},"id":2,"interval":null,"links":[],"mappingType":1,"mappingTypes":[{"name":"value to text","value":1},{"name":"range to text","value":2}],"maxDataPoints":100,"nullPointMode":"connected","nullText":null,"postfix":"","postfixFontSize":"50%","prefix":"","prefixFontSize":"50%","rangeMaps":[{"from":"null","text":"N/A","to":"null"}],"sparkline":{"fillColor":"rgba(31, 118, 189, 0.18)","full":false,"lineColor":"rgb(31, 120, 193)","show":false},"tableColumn":"","targets":[{"expr":"max(kube_statefulset_metadata_generation{statefulset=\"$statefulset_name\",namespace=\"$statefulset_namespace\"}) without (instance, pod)","intervalFactor":2,"refId":"A","step":600}],"thresholds":"","title":"Metadata Generation","type":"singlestat","valueFontSize":"80%","valueMaps":[{"op":"=","text":"0","value":"null"}],"valueName":"avg"},{"aliasColors":{},"bars":false,"dashLength":10,"dashes":false,"datasource":"RANCHER_MONITORING","editable":true,"error":false,"fill":1,"grid":{"threshold1Color":"rgba(216, 200, 27, 0.27)","threshold2Color":"rgba(234, 112, 112, 0.22)"},"gridPos":{"h":9,"w":24,"x":0,"y":8},"id":1,"isNew":true,"legend":{"alignAsTable":false,"avg":false,"current":false,"hideEmpty":false,"hideZero":false,"max":false,"min":false,"rightSide":false,"show":true,"total":false,"values":false},"lines":true,"linewidth":2,"links":[],"nullPointMode":"connected","percentage":false,"pointradius":5,"points":false,"renderer":"flot","seriesOverrides":[],"spaceLength":10,"stack":false,"steppedLine":false,"targets":[{"expr":"min(kube_statefulset_status_replicas{statefulset=\"$statefulset_name\",namespace=\"$statefulset_namespace\"}) without (instance, pod)","intervalFactor":2,"legendFormat":"Available","refId":"B","step":30},{"expr":"max(kube_statefulset_replicas{statefulset=\"$statefulset_name\",namespace=\"$statefulset_namespace\"}) without (instance, pod)","intervalFactor":2,"legendFormat":"Desired","refId":"E","step":30}],"thresholds":[],"timeFrom":null,"timeShift":null,"title":"Replicas","tooltip":{"msResolution":true,"shared":true,"sort":0,"value_type":"cumulative"},"type":"graph","xaxis":{"buckets":null,"mode":"time","name":null,"show":true,"values":[]},"yaxes":[{"format":"none","label":"","logBase":1,"show":true},{"format":"short","label":"","logBase":1,"show":false}],"yaxis":{"align":false,"alignLevel":null}}],"schemaVersion":16,"style":"dark","tags":[],"templating":{"list":[{"allValue":"","current":{},"datasource":"RANCHER_MONITORING","hide":0,"includeAll":false,"label":"Namespace","multi":false,"name":"statefulset_namespace","options":[],"query":"label_values(kube_statefulset_metadata_generation, namespace)","refresh":1,"regex":"","skipUrlSync":false,"sort":0,"tagValuesQuery":null,"tags":[],"tagsQuery":"","type":"query","useTags":false},{"allValue":"","current":{},"datasource":"RANCHER_MONITORING","hide":0,"includeAll":false,"label":"StatefulSet","multi":false,"name":"statefulset_name","options":[],"query":"label_values(kube_statefulset_metadata_generation{namespace=\"$statefulset_namespace\"}, statefulset)","refresh":1,"regex":"","skipUrlSync":false,"sort":0,"tagValuesQuery":"","tags":[],"tagsQuery":"statefulset","type":"query","useTags":false}]},"time":{"from":"now-5m","to":"now"},"timepicker":{"refresh_intervals":["5s","10s","30s","1m","5m","15m","30m","1h","2h","1d"],"time_options":["5m","15m","1h","6h","12h","24h","2d","7d","30d"]},"timezone":"browser","title":"StatefulSet","uid":"TDdTILbiz","version":1}
\ No newline at end of file
{{/* vim: set filetype=mustache: */}}
{{- define "app.dashboards.fullname" -}}
{{- $name := include "app.name" . -}}
{{- printf "%s-%s-dashboards" $name .Release.Name -}}
{{- end -}}
{{- define "app.provisionings.fullname" -}}
{{- $name := include "app.name" . -}}
{{- printf "%s-%s-provisionings" $name .Release.Name -}}
{{- end -}}
\ No newline at end of file
apiVersion: v1
kind: ConfigMap
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ template "app.dashboards.fullname" . }}
data:
{{- if eq .Values.level "cluster" }}
{{ (.Files.Glob "dashboards/c_*.json").AsConfig | indent 2 }}
{{- end }}
{{ (.Files.Glob "dashboards/w_*.json").AsConfig | indent 2 }}
apiVersion: {{ template "deployment_api_version" . }}
kind: Deployment
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ template "app.fullname" . }}
spec:
replicas: 1
selector:
matchLabels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
template:
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
spec:
initContainers:
- name: grafana-init-plugin-json-copy
image: {{ template "system_default_registry" . }}{{ .Values.image.repository }}:{{ .Values.image.tag }}
{{- if and .Values.resources .Values.resources.inits }}
resources:
{{ toYaml .Values.resources.inits | indent 10 }}
{{- end }}
volumeMounts:
- name: grafana-nginx
mountPath: /run.sh
subPath: copy-datasource-plugin-json.sh
- name: grafana-static-contents
mountPath: /host
- name: grafana-init-plugin-json-modify
image: {{ template "system_default_registry" . }}{{ .Values.image.tool.repository }}:{{ .Values.image.tool.tag }}
command:
- /run.sh
{{- if and .Values.resources .Values.resources.inits }}
resources:
{{ toYaml .Values.resources.inits | indent 10 }}
{{- end }}
volumeMounts:
- name: grafana-nginx
mountPath: /run.sh
subPath: modify-datasource-plugin-json.sh
- name: grafana-static-contents
mountPath: /host
containers:
- name: grafana
image: {{ template "system_default_registry" . }}{{ .Values.image.repository }}:{{ .Values.image.tag }}
env:
- name: GF_AUTH_BASIC_ENABLED
value: "true"
- name: GF_AUTH_ANONYMOUS_ENABLED
value: "true"
{{- if .Values.extraVars }}
{{ toYaml .Values.extraVars | indent 8 }}
{{- end }}
volumeMounts:
- name: grafana-storage
mountPath: /var/lib/grafana
- name: grafana-static-contents
mountPath: /usr/share/grafana/public/app/plugins/datasource/prometheus/plugin.json
subPath: grafana/plugin.json
- name: grafana-dashboards
mountPath: /var/lib/grafana/rancher-dashboards
- name: grafana-provisionings
mountPath: /etc/grafana/provisioning/dashboards/all.yaml
subPath: dashboards.yaml
- name: grafana-provisionings
mountPath: /etc/grafana/provisioning/datasources/all.yaml
subPath: datasources.yaml
ports:
- name: web
containerPort: 3000
protocol: TCP
readinessProbe:
httpGet:
path: /api/health
port: 3000
periodSeconds: 1
timeoutSeconds: 1
successThreshold: 1
failureThreshold: 10
{{- if and .Values.resources .Values.resources.core }}
resources:
{{ toYaml .Values.resources.core | indent 10 }}
{{- end }}
- name: grafana-proxy
image: {{ template "system_default_registry" . }}{{ .Values.image.proxy.repository }}:{{ .Values.image.proxy.tag }}
args:
- nginx
- -g
- daemon off;
- -c
- /nginx/nginx.conf
ports:
- name: http
containerPort: 80
protocol: TCP
volumeMounts:
- mountPath: /nginx/
name: grafana-nginx
{{- if and .Values.resources .Values.resources.proxy }}
resources:
{{ toYaml .Values.resources.proxy | indent 10 }}
{{- end }}
nodeSelector:
beta.kubernetes.io/os: linux
{{- range .Values.nodeSelectors }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
{{- if .Values.enabledRBAC }}
serviceAccountName: {{ default (include "app.fullname" .) .Values.serviceAccountName }}
{{- end }}
{{- if .Values.tolerations }}
tolerations:
{{ toYaml .Values.tolerations | indent 8 }}
{{- end }}
securityContext:
fsGroup: 472
volumes:
- name: grafana-static-contents
emptyDir: {}
- name: grafana-storage
{{- if or .Values.storageSpec .Values.persistence.enabled }}
persistentVolumeClaim:
claimName: {{ template "app.fullname" . }}
{{- else }}
emptyDir: {}
{{- end }}
- name: grafana-nginx
configMap:
name: {{ template "app.nginx.fullname" . }}
items:
- key: nginx.conf
mode: 438
path: nginx.conf
- key: copy-datasource-plugin-json.sh
mode: 0777
path: copy-datasource-plugin-json.sh
- key: modify-datasource-plugin-json.sh
mode: 0777
path: modify-datasource-plugin-json.sh
- name: grafana-dashboards
configMap:
name: {{ template "app.dashboards.fullname" . }}
- name: grafana-provisionings
configMap:
name: {{ template "app.provisionings.fullname" . }}
apiVersion: v1
kind: Service
metadata:
name: expose-grafana-metrics
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
{{ .Values.apiGroup }}: "true"
spec:
type: ClusterIP
clusterIP: None
selector:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
ports:
- name: metrics
port: 3000
targetPort: web
\ No newline at end of file
apiVersion: v1
kind: ConfigMap
metadata:
name: {{ template "app.nginx.fullname" . }}
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
component: nginx
data:
copy-datasource-plugin-json.sh: |-
#!/bin/bash
srcpath="/usr/share/grafana/public/app/plugins/datasource/prometheus/plugin.json"
dstpath="/host/grafana/raw-plugin.json"
if [[ -f $srcpath ]] && [[ -d /host ]]; then
mkdir -p /host/grafana
cp -f $srcpath $dstpath
exit 0
fi
exit 1
modify-datasource-plugin-json.sh: |-
#!/bin/sh
srcpath="/host/grafana/raw-plugin.json"
dstpath="/host/grafana/plugin.json"
if [ -f $srcpath ] && [ -d /host ]; then
mkdir -p /host/grafana
token=$(cat /var/run/secrets/kubernetes.io/serviceaccount/token)
cat $srcpath | K8S_BEARERTOKEN="Bearer $token" jq 'to_entries | . + [{"key":"routes","value":[{"path":"api/v1","url":"{{ .Values.prometheusDatasourceURL }}/api/v1","headers":[{"name":"Authorization","content":env.K8S_BEARERTOKEN}]}]}] | from_entries' > $dstpath
exit 0
fi
exit 1
nginx.conf: |-
user nginx;
worker_processes auto;
error_log /dev/stdout warn;
pid /var/run/nginx.pid;
events {
worker_connections 1024;
}
http {
include /etc/nginx/mime.types;
log_format main '[$time_local - $status] $remote_addr - $remote_user $request ($http_referer)';
proxy_connect_timeout 10;
proxy_read_timeout 180;
proxy_send_timeout 5;
proxy_buffer_size 16k;
proxy_buffers 4 32k;
proxy_busy_buffers_size 64k;
proxy_temp_file_write_size 64k;
proxy_temp_path /tmp/temp_dir;
proxy_cache_path /tmp/nginx levels=1:2 keys_zone=my_zone:100m inactive=1d max_size=10g;
server {
listen 80;
access_log off;
gzip on;
gzip_min_length 1k;
gzip_comp_level 2;
gzip_types text/plain application/javascript application/x-javascript text/css application/xml text/javascript image/jpeg image/gif image/png;
gzip_vary on;
gzip_disable "MSIE [1-6]\.";
proxy_set_header Host $host;
location /api/dashboards {
proxy_pass http://localhost:3000;
}
location /api/search {
proxy_pass http://localhost:3000;
sub_filter_types application/json;
sub_filter_once off;
sub_filter '"url":"/d' '"url":"d';
}
location / {
proxy_cache my_zone;
proxy_cache_valid 200 302 1d;
proxy_cache_valid 301 30d;
proxy_cache_valid any 5m;
proxy_cache_bypass $http_cache_control;
add_header X-Proxy-Cache $upstream_cache_status;
add_header Cache-Control "public";
proxy_pass http://localhost:3000/;
sub_filter_types text/html;
sub_filter_once off;
sub_filter '"appSubUrl":""' '"appSubUrl":"."';
sub_filter '"url":"/' '"url":"./';
sub_filter ':"/avatar/' ':"avatar/';
if ($request_filename ~ .*\.(?:js|css|jpg|jpeg|gif|png|ico|cur|gz|svg|svgz|mp4|ogg|ogv|webm)$) {
expires 90d;
}
}
}
}
apiVersion: v1
kind: ConfigMap
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ template "app.provisionings.fullname" . }}
data:
dashboards.yaml: |+
- name: RANCHER_MONITORING
orgId: 1
folder: ''
type: file
disableDeletion: false
updateIntervalSeconds: 0 #never
options:
path: /var/lib/grafana/rancher-dashboards
datasources.yaml: |+
apiVersion: 1
datasources:
- name: RANCHER_MONITORING
type: prometheus
access: proxy
basicAuth: false
editable: false
isDefault: true
url: {{ .Values.prometheusDatasourceURL }}
\ No newline at end of file
{{- if or .Values.storageSpec .Values.persistence.enabled -}}
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ template "app.fullname" . }}
spec:
{{- if .Values.storageSpec }}
{{ toYaml .Values.storageSpec | indent 2 }}
{{- else }}
accessModes:
- {{ default "ReadWriteOnce" .Values.persistence.accessMode }}
{{ if and .Values.persistence.storageClass (ne "default" .Values.persistence.storageClass) }}
storageClassName: {{ .Values.persistence.storageClass }}
{{ end }}
resources:
requests:
storage: {{ .Values.persistence.size | quote }}
{{- end }}
{{- end -}}
{{- if and .Values.enabledRBAC (not .Values.serviceAccountName) }}
apiVersion: v1
kind: ServiceAccount
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ template "app.fullname" . }}
imagePullSecrets:
{{ toYaml .Values.image.pullSecrets | indent 2 }}
{{- end }}
\ No newline at end of file
apiVersion: v1
kind: Service
metadata:
name: access-grafana
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
kubernetes.io/cluster-service: "true"
spec:
type: ClusterIP
sessionAffinity: ClientIP
selector:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
ports:
- name: http
port: 80
targetPort: http
apiVersion: {{ template "operator_api_version" . }}
kind: ServiceMonitor
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
source: rancher-monitoring
name: {{ template "app.fullname" . }}
spec:
selector:
matchLabels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
{{ .Values.apiGroup }}: "true"
namespaceSelector:
matchNames:
- {{ .Release.Namespace | quote }}
endpoints:
- port: metrics
interval: 30s
relabelings:
- sourceLabels:
- __meta_kubernetes_pod_host_ip
targetLabel: host_ip
action: replace
regex: (.+)
replacement: $1
- sourceLabels:
- __meta_kubernetes_pod_node_name
targetLabel: node
action: replace
regex: (.+)
replacement: $1
enabledRBAC: true
## Tolerations for use with node taints
## Ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/
##
tolerations: []
# - key: "key"
# operator: "Equal"
# value: "value"
# effect: "NoSchedule"
## Pass extra environment variables to the Grafana container.
##
# extraVars:
# - name: EXTRA_VAR_1
# value: extra-var-value-1
# - name: EXTRA_VAR_2
# value: extra-var-value-2
extraVars:
storageSpec: {}
# storageClassName: default
# accessModes:
# - ReadWriteOnce
# resources:
# requests:
# storage: 2Gi
# selector: {}
## Resource limits & requests
## Ref: https://kubernetes.io/docs/user-guide/compute-resources/
resources:
inits:
limits:
memory: 50Mi
cpu: 50m
requests:
memory: 50Mi
cpu: 50m
core:
limits:
memory: 200Mi
cpu: 200m
requests:
memory: 100Mi
cpu: 100m
proxy:
limits:
memory: 100Mi
cpu: 100m
requests:
memory: 50Mi
cpu: 50m
apiVersion: v1
description: Creates Prometheus CRD instance for Kubernetes which maintaining by Rancher 2.
engine: gotpl
maintainers:
- name: thxCode
email: frank@rancher.com
name: prometheus
version: 0.0.1
- job_name: 'prometheus-io-scrape'
kubernetes_sd_configs:
- role: pod
namespaces:
names:
- {{ .Release.Namespace }}
- ingress-nginx
- ingress-controller
- kube-system
relabel_configs:
- source_labels: [__meta_kubernetes_pod_annotation_prometheus_io_scrape]
action: keep
regex: true
- source_labels: [__meta_kubernetes_pod_annotation_prometheus_io_scheme]
action: replace
target_label: __scheme__
regex: (https?)
- source_labels: [__meta_kubernetes_pod_annotation_prometheus_io_path]
action: replace
target_label: __metrics_path__
regex: (.+)
- source_labels: [__address__, __meta_kubernetes_pod_annotation_prometheus_io_port]
action: replace
target_label: __address__
regex: ([^:]+)(?::\d+)?;(\d+)
replacement: $1:$2
- source_labels: [__meta_kubernetes_pod_node_name]
action: replace
target_label: node
regex: (.+)
replacement: $1
- source_labels: [__meta_kubernetes_namespace]
action: replace
target_label: namespace
regex: (.+)
replacement: $1
- source_labels: [__meta_kubernetes_pod_name]
action: replace
target_label: pod
regex: (.+)
replacement: $1
- source_labels: [__meta_kubernetes_pod_ip]
action: replace
target_label: pod_ip
regex: (.+)
replacement: $1
- source_labels: [__meta_kubernetes_pod_host_ip]
action: replace
target_label: host_ip
regex: (.+)
replacement: $1
- source_labels: [__meta_kubernetes_pod_controller_kind]
action: replace
target_label: created_by_kind
regex: (.+)
replacement: $1
- source_labels: [__meta_kubernetes_pod_controller_name]
action: replace
target_label: created_by_kind
regex: (.+)
replacement: $1
\ No newline at end of file
{{- if and (eq .Values.level "project") (eq .Values.sync.mode "federate") }}
- job_name: 'federate'
scrape_interval: 15s
honor_labels: true
metrics_path: {{ .Values.sync.path }}
params:
'match[]':
- '{__name__=~".+"}'
bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token
static_configs:
- targets:
- {{ trimPrefix "https://" (trimPrefix "http://" .Values.sync.target) }}
{{- end }}
{{/* vim: set filetype=mustache: */}}
{{- define "additional-scrape-configs.yaml" -}}
{{- $root := . -}}
{{- $yamls := dict -}}
{{- if eq .Values.level "cluster" -}}
{{- range $path, $bytes := .Files.Glob "additionals/c-scrape_*.yaml" -}}
{{- $tpl := tpl ($bytes | toString) $root }}
{{- if $tpl }}
{{- $_ := set $yamls $tpl "" -}}
{{- end }}
{{- end -}}
{{- end -}}
{{- range $path, $bytes := .Files.Glob "additionals/w-scrape_*.yaml" -}}
{{- $tpl := tpl ($bytes | toString) $root }}
{{- if $tpl }}
{{- $_ := set $yamls $tpl "" -}}
{{- end }}
{{- end -}}
{{- if .Values.additionalScrapeConfigs -}}
{{- $_ := set $yamls (.Values.additionalScrapeConfigs | toYaml) "" -}}
{{- end -}}
{{- if $yamls -}}
{{- keys $yamls | join "\n" | quote -}}
{{- end -}}
{{- end -}}
{{- define "additional-alertmanager-configs.yaml" -}}
{{- $root := . -}}
{{- $yamls := dict -}}
{{- if eq .Values.level "cluster" -}}
{{- range $path, $bytes := .Files.Glob "additionals/c-altermanager_*.yaml" -}}
{{- $tpl := tpl ($bytes | toString) $root }}
{{- if $tpl }}
{{- $_ := set $yamls $tpl "" -}}
{{- end }}
{{- end -}}
{{- end -}}
{{- range $path, $bytes := .Files.Glob "additionals/w-altermanager_*.yaml" -}}
{{- $tpl := tpl ($bytes | toString) $root }}
{{- if $tpl }}
{{- $_ := set $yamls $tpl "" -}}
{{- end }}
{{- end -}}
{{- if .Values.additionalAlertManagerConfigs -}}
{{- $_ := set $yamls (.Values.additionalAlertManagerConfigs | toYaml) "" -}}
{{- end -}}
{{- if $yamls -}}
{{- keys $yamls | join "\n" | quote -}}
{{- end -}}
{{- end -}}
{{- define "app.auth.fullname" -}}
{{- $name := include "app.name" . -}}
{{- printf "%s-auth-%s" $name .Release.Name -}}
{{- end -}}
apiVersion: v1
kind: Service
metadata:
name: expose-prometheus-metrics
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
{{ .Values.apiGroup }}: "true"
spec:
type: ClusterIP
clusterIP: None
selector:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
ports:
- name: metrics
port: 9090
targetPort: web
\ No newline at end of file
apiVersion: v1
kind: ConfigMap
metadata:
name: {{ template "app.nginx.fullname" . }}
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
data:
run-sh.tmpl: |-
#!/bin/sh
set -e
srcpath="/nginx/nginx-conf.tmpl"
dstpath="/var/run/nginx.conf"
if ! [ -f $srcpath ]; then
exit 1
fi
token=$(cat /var/run/secrets/kubernetes.io/serviceaccount/token)
sed "s/REPLACE_PARAM_AUTHORIZATION/Bearer ${token}/g" $srcpath | sed "s/REPLACE_PARAM_IP/${POD_IP}/g" > $dstpath
exec nginx -g "daemon off;" -c /var/run/nginx.conf
nginx-conf.tmpl: |-
user nginx;
worker_processes auto;
error_log /dev/stdout warn;
pid /var/run/nginx.pid;
events {
worker_connections 1024;
}
http {
include /etc/nginx/mime.types;
log_format main '[$time_local - $status] $remote_addr - $remote_user $request ($http_referer)';
proxy_connect_timeout 10;
proxy_read_timeout 180;
proxy_send_timeout 5;
proxy_buffer_size 16k;
proxy_buffers 4 32k;
proxy_busy_buffers_size 64k;
proxy_temp_file_write_size 64k;
proxy_temp_path /tmp/temp_dir;
proxy_cache_path /tmp/nginx levels=1:2 keys_zone=my_zone:100m inactive=1d max_size=10g;
server {
listen 80;
access_log off;
gzip on;
gzip_min_length 1k;
gzip_comp_level 2;
gzip_types text/plain application/javascript application/x-javascript text/css application/xml text/javascript image/jpeg image/gif image/png;
gzip_vary on;
gzip_disable "MSIE [1-6]\.";
proxy_set_header Host $host;
proxy_set_header Authorization "REPLACE_PARAM_AUTHORIZATION";
proxy_pass_header Authorization;
location / {
proxy_cache my_zone;
proxy_cache_valid 200 302 1d;
proxy_cache_valid 301 30d;
proxy_cache_valid any 5m;
proxy_cache_bypass $http_cache_control;
add_header X-Proxy-Cache $upstream_cache_status;
add_header Cache-Control "public";
proxy_pass http://REPLACE_PARAM_IP:9090/;
sub_filter_types text/html;
sub_filter_once off;
sub_filter 'var PATH_PREFIX = "";' 'var PATH_PREFIX = ".";';
if ($request_filename ~ .*\.(?:js|css|jpg|jpeg|gif|png|ico|cur|gz|svg|svgz|mp4|ogg|ogv|webm)$) {
expires 90d;
}
}
}
}
\ No newline at end of file
apiVersion: {{ template "operator_api_version" . }}
kind: Prometheus
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ .Release.Name }}
spec:
{{- if .Values.securityContext }}
securityContext:
{{ toYaml .Values.securityContext | indent 4 }}
{{- end }}
containers:
- name: prometheus-proxy
command:
- /bin/sh
- -c
- cp /nginx/run-sh.tmpl /var/run/nginx-start.sh; chmod +x /var/run/nginx-start.sh; /var/run/nginx-start.sh
env:
- name: POD_IP
valueFrom:
fieldRef:
fieldPath: status.podIP
image: {{ template "system_default_registry" . }}{{ .Values.image.proxy.repository }}:{{ .Values.image.proxy.tag }}
ports:
- containerPort: 80
name: http
protocol: TCP
{{- if and .Values.resources .Values.resources.proxy }}
resources:
{{ toYaml .Values.resources.proxy | indent 6 }}
{{- end }}
securityContext:
runAsNonRoot: false
runAsUser: 0
volumeMounts:
- mountPath: /nginx
name: configmap-{{ template "app.nginx.fullname" . }}
{{- if eq .Values.level "cluster" }}
- name: prometheus-agent
command:
- prometheus-auth
{{- if and .Values.auth .Values.auth.args }}
args:
{{ toYaml .Values.auth.args | indent 6 }}
{{- end }}
{{- if and .Values.auth .Values.auth.env }}
env:
{{ toYaml .Values.auth.env | indent 6 }}
{{- end }}
image: {{ template "system_default_registry" . }}{{ .Values.image.auth.repository }}:{{ .Values.image.auth.tag }}
ports:
- containerPort: 9090
name: web
protocol: TCP
livenessProbe:
failureThreshold: 6
httpGet:
path: /-/healthy
port: web
scheme: HTTP
periodSeconds: 10
successThreshold: 1
timeoutSeconds: 10
readinessProbe:
failureThreshold: 10
httpGet:
path: /-/ready
port: web
scheme: HTTP
periodSeconds: 10
successThreshold: 1
timeoutSeconds: 10
{{- if and .Values.resources .Values.resources.auth }}
resources:
{{ toYaml .Values.resources.auth | indent 6 }}
{{- end }}
listenLocal: true
{{- end }}
podMetadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
{{- if .Values.alertingEndpoints }}
alerting:
alertmanagers:
{{ toYaml .Values.alertingEndpoints | indent 6 }}
{{- else if not (include "additional-alertmanager-configs.yaml" .) }}
alerting:
alertmanagers:
- namespace: {{ .Release.Namespace }}
name: alertmanager-operated
port: http
{{- end }}
baseImage: {{ template "system_default_registry" . }}{{ .Values.image.repository }}
{{- if .Values.externalLabels }}
externalLabels:
{{ toYaml .Values.externalLabels | indent 4}}
{{- end }}
nodeSelector:
beta.kubernetes.io/os: linux
{{- range .Values.nodeSelectors }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
paused: {{ .Values.paused }}
replicas: {{ .Values.replicaCount }}
logLevel: {{ .Values.logLevel }}
{{- if and .Values.resources .Values.resources.core }}
resources:
{{ toYaml .Values.resources.core | indent 4 }}
{{- end }}
retention: "{{ .Values.retention }}"
configMaps:
- {{ template "app.nginx.fullname" . }}
{{- if .Values.secrets }}
secrets:
{{ toYaml .Values.secrets | indent 2 }}
{{- end }}
{{- if .Values.enabledRBAC }}
serviceAccountName: {{ default (default (include "app.fullname" .) .Values.serviceAccountName) .Values.serviceAccountNameOverride }}
{{- end }}
{{- if .Values.serviceMonitorNamespaceSelector }}
serviceMonitorNamespaceSelector:
{{ toYaml .Values.serviceMonitorNamespaceSelector | indent 4 }}
{{- end }}
{{- if .Values.serviceMonitorSelector }}
serviceMonitorSelector:
{{ toYaml .Values.serviceMonitorSelector | indent 4 }}
{{- end }}
{{- if and (eq .Values.level "project") (eq .Values.sync.mode "remote") }}
remoteRead:
- bearerTokenFile: /var/run/secrets/kubernetes.io/serviceaccount/token
url: {{ printf "%s%s" .Values.sync.target .Values.sync.path }}
{{- end }}
{{- if .Values.ruleNamespaceSelector }}
ruleNamespaceSelector:
{{ toYaml .Values.ruleNamespaceSelector | indent 4 }}
{{- end }}
{{- if .Values.ruleSelector }}
ruleSelector:
{{ toYaml .Values.ruleSelector | indent 4 }}
{{- end }}
{{- if or .Values.storageSpec .Values.persistence.enabled }}
storage:
volumeClaimTemplate:
spec:
{{- if .Values.storageSpec }}
{{ toYaml .Values.storageSpec | indent 8 }}
{{- else }}
{{ if and .Values.persistence.storageClass (ne "default" .Values.persistence.storageClass) }}
storageClassName: {{ .Values.persistence.storageClass }}
{{ end }}
accessModes:
- {{ default "ReadWriteOnce" .Values.persistence.accessMode }}
resources:
requests:
storage: {{ .Values.persistence.size | quote }}
{{- end }}
{{- end }}
version: "{{ .Values.image.tag }}"
affinity:
podAntiAffinity:
preferredDuringSchedulingIgnoredDuringExecution:
- weight: 100
podAffinityTerm:
topologyKey: kubernetes.io/hostname
labelSelector:
matchLabels:
app: {{ template "app.name" . }}
prometheus: {{ .Release.Name }}
{{- if .Values.tolerations }}
tolerations:
{{ toYaml .Values.tolerations | indent 4 }}
{{- end }}
{{- if (include "additional-scrape-configs.yaml" .) }}
additionalScrapeConfigs:
name: {{ template "app.fullname" . }}-additional-scrape-configs
key: additional-scrape-configs.yaml
{{- end }}
{{- if (include "additional-alertmanager-configs.yaml" .) }}
additionalAlertManagerConfigs:
name: {{ template "app.fullname" . }}-additional-alertmanager-configs
key: additional-alertmanager-configs.yaml
{{- end }}
{{- if and .Values.enabledRBAC (not .Values.serviceAccountName) }}
apiVersion: v1
kind: ServiceAccount
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ default (include "app.fullname" .) .Values.serviceAccountNameOverride }}
imagePullSecrets:
{{ toYaml .Values.image.pullSecrets | indent 2 }}
---
apiVersion: {{ template "rbac_api_version" . }}
kind: ClusterRole
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ include "app.fullname" . }}-{{ .Release.Namespace }}
rules:
- nonResourceURLs:
- "/metrics"
verbs:
- "get"
- apiGroups:
- "extensions"
verbs:
- "list"
- "watch"
resources:
- ingresses
- apiGroups:
- ""
verbs:
- "list"
- "watch"
resources:
- services
- endpoints
- pods
{{- if eq .Values.level "cluster" }}
- nodes
- apiGroups:
- ""
resources:
- nodes/metrics
verbs:
- "get"
- apiGroups:
- ""
resources:
- namespaces
- secrets
verbs:
- "list"
- "watch"
- "get"
- apiGroups:
- authorization.k8s.io
resources:
- subjectaccessreviews
verbs:
- "create"
{{- end }}
---
apiVersion: {{ template "rbac_api_version" . }}
kind: ClusterRoleBinding
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ include "app.fullname" . }}-{{ .Release.Namespace }}
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
name: {{ include "app.fullname" . }}-{{ .Release.Namespace }}
subjects:
- kind: ServiceAccount
name: {{ default (include "app.fullname" .) .Values.serviceAccountNameOverride }}
namespace: {{ .Release.Namespace }}
{{- if eq .Values.level "project" }}
---
apiVersion: {{ template "rbac_api_version" . }}
kind: Role
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ include "app.fullname" . }}
rules:
- apiGroups:
- "monitoring.cattle.io"
resources:
- prometheus
verbs:
- "view"
---
apiVersion: {{ template "rbac_api_version" . }}
kind: RoleBinding
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ include "app.fullname" . }}
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: Role
name: {{ include "app.fullname" . }}
namespace: {{ .Release.Namespace }}
subjects:
- kind: ServiceAccount
name: {{ default (include "app.fullname" .) .Values.serviceAccountNameOverride }}
namespace: {{ .Release.Namespace }}
{{- end }}
{{- $rbacAPIVersion := include "rbac_api_version" . }}
{{- $appServiceAccountName := default (include "app.fullname" .) .Values.serviceAccountNameOverride }}
{{- $appName := include "app.name" . }}
{{- $appVersion := include "app.version" . }}
{{- $root := . -}}
{{ range .Values.additionalBindingClusterRoles }}
---
apiVersion: {{ $rbacAPIVersion }}
kind: ClusterRoleBinding
metadata:
labels:
app: {{ $appName }}
chart: {{ $appVersion }}
heritage: {{ $root.Release.Service }}
release: {{ $root.Release.Name }}
name: {{ . }}-additional-binding
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
name: {{ . }}
subjects:
- kind: ServiceAccount
name: {{ $appServiceAccountName }}
namespace: {{ $root.Release.Namespace }}
{{ end }}
{{- end }}
{{- if (include "additional-scrape-configs.yaml" .) }}
apiVersion: v1
kind: Secret
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ template "app.fullname" . }}-additional-scrape-configs
stringData:
additional-scrape-configs.yaml: {{ template "additional-scrape-configs.yaml" . }}
{{- end }}
{{- if (include "additional-alertmanager-configs.yaml" .) }}
---
apiVersion: v1
kind: Secret
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ template "app.fullname" . }}-additional-alertmanager-configs
stringData:
additional-alertmanager-configs.yaml: {{ template "additional-alertmanager-configs.yaml" . }}
{{- end }}
\ No newline at end of file
apiVersion: v1
kind: Service
metadata:
name: access-prometheus
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
kubernetes.io/cluster-service: "true"
spec:
type: ClusterIP
sessionAffinity: ClientIP
selector:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
ports:
- name: http
port: 80
targetPort: http
apiVersion: {{ template "operator_api_version" . }}
kind: ServiceMonitor
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
source: rancher-monitoring
name: {{ template "app.fullname" . }}
spec:
selector:
matchLabels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
{{ .Values.apiGroup }}: "true"
namespaceSelector:
matchNames:
- {{ .Release.Namespace | quote }}
endpoints:
- port: metrics
interval: 30s
relabelings:
- sourceLabels:
- __meta_kubernetes_pod_host_ip
targetLabel: host_ip
action: replace
regex: (.+)
replacement: $1
- sourceLabels:
- __meta_kubernetes_pod_node_name
targetLabel: node
action: replace
regex: (.+)
replacement: $1
{{- if eq .Values.level "cluster" }}
- port: metrics
interval: 15s
path: /_/metrics
metricRelabelings:
- sourceLabels:
- job
targetLabel: job
action: replace
regex: (.+)
replacement: expose-prometheus-auth-metrics
relabelings:
- sourceLabels:
- __meta_kubernetes_pod_host_ip
targetLabel: host_ip
action: replace
regex: (.+)
replacement: $1
- sourceLabels:
- __meta_kubernetes_pod_node_name
targetLabel: node
action: replace
regex: (.+)
replacement: $1
{{- end }}
enabledRBAC: true
## External labels to add to any time series or alerts when communicating with external systems
##
externalLabels: {}
##Custom Labels to be added to Prometheus Rules CRDs
##
additionalRulesLabels: {}
## Tolerations for use with node taints
## Ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/
##
tolerations: []
# - key: "key"
# operator: "Equal"
# value: "value"
# effect: "NoSchedule"
## If true, the Operator won't process any Prometheus configuration changes
##
paused: false
## Number of Prometheus replicas desired
##
replicaCount: 1
## The remote_read spec configuration for Prometheus.
## Ref: https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#remotereadspec
remoteRead: []
# - url: http://remote1/read
## The remote_write spec configuriation for Prometheus.
## Ref: https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#remotewritespec
remoteWrite: []
# - url: http://remote1/push
## How long to retain metrics
##
retention: 24h
logLevel: "info"
## Prometheus StorageSpec for persistent data
## Ref: https://github.com/coreos/prometheus-operator/blob/master/Documentation/user-guides/storage.md
##
storageSpec: {}
# storageClassName: gluster
# accessModes: ["ReadWriteOnce"]
# resources:
# requests:
# storage: 50Gi
# selector: {}
## Prometheus AdditionalScrapeConfigs
## Ref: https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#prometheusspec
##
additionalScrapeConfigs: []
# - job_name: "prometheus"
# static_configs:
# - targets:
# - "localhost:9090"
## Prometheus AdditionalAlertManagerConfigs
## Ref: https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#prometheusspec
##
additionalAlertManagerConfigs: []
# - static_configs:
# - targets:
# - "localhost:9093"
categories:
- Monitoring
questions:
dependencies:
- name: alertmanager
version: 0.0.1
condition: alertmanager.enabled
repository: "file://./charts/alertmanager/"
- name: exporter-coredns
version: 0.0.1
condition: exporter-coredns.enabled
repository: "file://./charts/exporter-coredns/"
- name: exporter-kube-controller-manager
version: 0.0.1
condition: exporter-kube-controller-manager.enabled
repository: "file://./charts/exporter-kube-controller-manager/"
- name: exporter-kube-dns
version: 0.0.1
condition: exporter-kube-dns.enabled
repository: "file://./charts/exporter-kube-dns/"
- name: exporter-kube-etcd
version: 0.0.1
condition: exporter-kube-etcd.enabled
repository: "file://./charts/exporter-kube-etcd/"
- name: exporter-kube-scheduler
version: 0.0.1
condition: exporter-kube-scheduler.enabled
repository: "file://./charts/exporter-kube-scheduler/"
- name: exporter-kube-state
version: 0.0.1
condition: exporter-kube-state.enabled
repository: "file://./charts/exporter-kube-state/"
- name: exporter-kubelets
version: 0.0.1
condition: exporter-kubelets.enabled
repository: "file://./charts/exporter-kubelets/"
- name: exporter-kubernetes
version: 0.0.1
condition: exporter-kubernetes.enabled
repository: "file://./charts/exporter-kubernetes/"
- name: exporter-node
version: 0.0.1
condition: exporter-node.enabled
repository: "file://./charts/exporter-node/"
- name: grafana
version: 0.0.1
condition: grafana.enabled
repository: "file://./charts/grafana/"
- name: prometheus
version: 0.0.1
condition: prometheus.enabled
repository: "file://./charts/prometheus/"
- name: exporter-fluentd
version: 0.0.1
condition: exporter-fluentd.enabled
repository: "file://./charts/exporter-fluentd/"
\ No newline at end of file
{{/* vim: set filetype=mustache: */}}
{{- define "charts.exporter-kubelets.fullname" -}}
{{- printf "exporter-kubelets-%s" .Release.Name -}}
{{- end -}}
{{- define "charts.prometheus.serviceaccount.fullname" -}}
{{- printf "prometheus-%s" .Release.Name -}}
{{- end -}}
{{- define "app.name" -}}
{{- default .Chart.Name .Values.nameOverride -}}
{{- end -}}
{{- define "app.version" -}}
{{- $name := include "app.name" . -}}
{{- $version := .Chart.Version | replace "+" "_" -}}
{{- printf "%s-%s" $name $version -}}
{{- end -}}
{{- define "app.fullname" -}}
{{- $name := include "app.name" . -}}
{{- printf "%s-%s" $name .Release.Name -}}
{{- end -}}
{{- define "app.dnsname" -}}
{{- include "app.fullname" . | trunc 63 | trimSuffix "-" -}}
{{- end -}}
{{- define "app.psp.fullname" -}}
{{- $name := include "app.name" . -}}
{{- printf "%s-%s-psp" $name .Release.Name -}}
{{- end -}}
{{- define "app.nginx.fullname" -}}
{{- $name := include "app.name" . -}}
{{- printf "%s-%s-nginx" $name .Release.Name -}}
{{- end -}}
{{- define "app.hooks.fullname" -}}
{{- $name := include "app.name" . -}}
{{- printf "%s-%s-hooks" $name .Release.Name -}}
{{- end -}}
{{- define "app.cleanup.fullname" -}}
{{- $name := include "app.name" . -}}
{{- printf "%s-%s-cleanup" $name .Release.Name -}}
{{- end -}}
{{- define "kube_version" -}}
{{- printf "%s.%s" .Capabilities.KubeVersion.Major .Capabilities.KubeVersion.Minor -}}
{{- end -}}
{{- define "operator_api_version" -}}
{{- default "monitoring.coreos.com/v1" (.Values.apiGroup | printf "%s/v1") -}}
{{- end -}}
{{- define "operator_api_group" -}}
{{- $apiVersion := include "operator_api_version" . -}}
{{- index (regexSplit "/" $apiVersion 2) 0 | printf "%s" -}}
{{- end -}}
{{- define "deployment_api_version" -}}
{{- if .Capabilities.APIVersions.Has "apps/v1" -}}
{{- "apps/v1" -}}
{{- else if .Capabilities.APIVersions.Has "apps/v1beta2" -}}
{{- "apps/v1beta1" -}}
{{- else if .Capabilities.APIVersions.Has "apps/v1beta1" -}}
{{- "apps/v1beta1" -}}
{{- else -}}
{{- "extensions/v1beta1" -}}
{{- end -}}
{{- end -}}
{{- define "statefulset_api_version" -}}
{{- if .Capabilities.APIVersions.Has "apps/v1" -}}
{{- "apps/v1" -}}
{{- else if .Capabilities.APIVersions.Has "apps/v1beta2" -}}
{{- "apps/v1beta2" -}}
{{- else -}}
{{- "apps/v1beta1" -}}
{{- end -}}
{{- end -}}
{{- define "daemonset_api_version" -}}
{{- if .Capabilities.APIVersions.Has "apps/v1" -}}
{{- "apps/v1" -}}
{{- else if .Capabilities.APIVersions.Has "apps/v1beta2" -}}
{{- "apps/v1beta2" -}}
{{- else -}}
{{- "extensions/v1beta1" -}}
{{- end -}}
{{- end -}}
{{- define "rbac_api_version" -}}
{{- if .Capabilities.APIVersions.Has "rbac.authorization.k8s.io/v1" -}}
{{- "rbac.authorization.k8s.io/v1" -}}
{{- else if .Capabilities.APIVersions.Has "rbac.authorization.k8s.io/v1beta1" -}}
{{- "rbac.authorization.k8s.io/v1beta1" -}}
{{- else -}}
{{- "rbac.authorization.k8s.io/v1alpha1" -}}
{{- end -}}
{{- end -}}
{{- define "system_default_registry" -}}
{{- if .Values.global.systemDefaultRegistry -}}
{{- printf "%s/" .Values.global.systemDefaultRegistry -}}
{{- else -}}
{{- "" -}}
{{- end -}}
{{- end -}}
{{- if .Values.enabled }}
{{- $kubeletSvcName := "expose-kubelets-metrics" -}}
apiVersion: v1
kind: Service
metadata:
name: {{ $kubeletSvcName }}
labels:
k8s-app: kubelet
{{ .Values.apiGroup }}: "true"
spec:
type: ClusterIP
clusterIP: None
ports:
- name: https-metrics
port: 10250
targetPort: 10250
---
apiVersion: {{ template "deployment_api_version" . }}
kind: Deployment
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ template "app.fullname" . }}
spec:
replicas: 1
selector:
matchLabels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
template:
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
spec:
containers:
- name: prometheus-operator
image: {{ template "system_default_registry" . }}{{ .Values.image.repository }}:{{ .Values.image.tag }}
args:
- --kubelet-service={{ .Release.Namespace }}/{{ $kubeletSvcName }}
- --log-format={{ .Values.logFormat }}
- --log-level={{ .Values.logLevel }}
- --prometheus-config-reloader={{ template "system_default_registry" . }}{{ .Values.image.prometheusConfigReloader.repository }}:{{ .Values.image.prometheusConfigReloader.tag }}
- --config-reloader-image={{ template "system_default_registry" . }}{{ .Values.image.configmapReload.repository }}:{{ .Values.image.configmapReload.tag }}
- --labels={{ .Values.apiGroup }}=true
- --crd-apigroup={{ template "operator_api_group" . }}
- --manage-crds={{ .Values.manageCRDs }}
- --with-validation={{ .Values.withValidation }}
ports:
- containerPort: 8080
name: http
resources:
{{ toYaml .Values.resources | indent 12 }}
nodeSelector:
beta.kubernetes.io/os: linux
{{- range .Values.nodeSelectors }}
{{- $pair := regexSplit "=" . 2 }}
{{- if eq 2 (len $pair) }}
{{ (index $pair 0) }}: {{ (index $pair 1) }}
{{- else }}
{{ (index $pair 0) }}: ""
{{- end }}
{{- end }}
{{- if .Values.enabledRBAC }}
serviceAccountName: {{ default (include "app.fullname" .) .Values.serviceAccountName }}
{{- end }}
{{- if .Values.tolerations }}
tolerations:
{{ toYaml .Values.tolerations | indent 8 }}
{{- end }}
{{- end }}
{{- if .Values.enabled }}
apiVersion: v1
kind: Service
metadata:
name: expose-operator-metrics
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
{{ .Values.apiGroup }}: "true"
spec:
type: ClusterIP
clusterIP: None
selector:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
ports:
- name: metrics
port: 8080
targetPort: http
{{- end }}
\ No newline at end of file
{{- if .Values.enabled }}
{{- if and .Values.enabledRBAC (not .Values.serviceAccountName) }}
apiVersion: {{ template "rbac_api_version" . }}
kind: ClusterRole
metadata:
name: {{ template "app.fullname" . }}
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
rules:
- apiGroups:
- {{ template "operator_api_group" . }}
resources:
- alertmanager
- alertmanagers
- prometheus
- prometheuses
- service-monitor
- servicemonitors
- prometheusrules
- prometheuses/finalizers
- alertmanagers/finalizers
verbs:
- "*"
- apiGroups:
- apps
resources:
- statefulsets
verbs:
- "*"
- apiGroups: [""]
resources:
- configmaps
- secrets
verbs:
- "*"
- apiGroups: [""]
resources:
- pods
verbs:
- list
- delete
- apiGroups: [""]
resources:
- services
- endpoints
verbs:
- get
- create
- update
- apiGroups: [""]
resources:
- nodes
- namespaces
verbs:
- list
- watch
---
apiVersion: v1
kind: ServiceAccount
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
name: {{ template "app.fullname" . }}
imagePullSecrets:
{{ toYaml .Values.imagePullSecrets | indent 2 }}
---
apiVersion: {{ template "rbac_api_version" . }}
kind: ClusterRoleBinding
metadata:
name: {{ template "app.fullname" . }}
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
name: {{ template "app.fullname" . }}
subjects:
- kind: ServiceAccount
name: {{ template "app.fullname" . }}
namespace: {{ .Release.Namespace }}
{{- end }}
{{- end }}
{{- if .Values.enabled }}
apiVersion: {{ template "operator_api_version" . }}
kind: ServiceMonitor
metadata:
labels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
heritage: {{ .Release.Service }}
release: {{ .Release.Name }}
source: rancher-monitoring
name: {{ template "app.fullname" . }}
spec:
selector:
matchLabels:
app: {{ template "app.name" . }}
chart: {{ template "app.version" . }}
release: {{ .Release.Name }}
{{ .Values.apiGroup }}: "true"
namespaceSelector:
matchNames:
- {{ .Release.Namespace | quote }}
endpoints:
- port: metrics
interval: 30s
honorLabels: true
relabelings:
- sourceLabels:
- __meta_kubernetes_pod_host_ip
action: replace
targetLabel: host_ip
regex: (.+)
replacement: $1
- sourceLabels:
- __meta_kubernetes_pod_node_name
action: replace
targetLabel: node
regex: (.+)
replacement: $1
{{- end }}
enabled: false
nameOverride: "prometheus-operator"
enabledRBAC: true
apiGroup: "monitoring.coreos.com"
image:
repository: rancher/coreos-prometheus-operator
tag: v0.29.0
prometheusConfigReloader:
repository: rancher/coreos-prometheus-config-reloader
tag: v0.29.0
configmapReload:
repository: rancher/coreos-configmap-reload
tag: v0.0.1
resources:
limits:
cpu: 200m
memory: 100Mi
requests:
cpu: 100m
memory: 50Mi
nodeSelectors: []
tolerations: []
logFormat: "logfmt"
logLevel: "info"
manageCRDs: false
withValidation: true
## Already exist ServiceAccount
##
serviceAccountName: ""
exporter-coredns:
enabled: false
apiGroup: "monitoring.coreos.com"
endpoints: []
ports:
metrics:
scheme: http
name: metrics
port: 9153
protocol: TCP
serviceSelectorLabels:
- "k8s-app=kube-dns"
insecureSkipVerify: true
exporter-kube-controller-manager:
enabled: false
apiGroup: "monitoring.coreos.com"
endpoints: []
ports:
metrics:
scheme: http
name: metrics
port: 10252
protocol: TCP
serviceSelectorLabels:
- "k8s-app=kube-controller-manager"
insecureSkipVerify: true
exporter-kube-dns:
enabled: false
apiGroup: "monitoring.coreos.com"
endpoints: []
ports:
metrics:
dnsmasq:
scheme: http
name: dnsmasq-metrics
port: 10054
protocol: TCP
skydns:
scheme: http
name: skydns-metrics
port: 10055
protocol: TCP
serviceSelectorLabels:
- "k8s-app=kube-dns"
insecureSkipVerify: true
exporter-kube-etcd:
enabled: false
apiGroup: "monitoring.coreos.com"
endpoints: []
ports:
metrics:
scheme: https
name: metrics
port: 4001
protocol: TCP
serviceSelectorLabels:
- "k8s-app=etcd-server"
insecureSkipVerify: true
caFile: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt
certFile: ""
keyFile: ""
exporter-kube-scheduler:
enabled: false
apiGroup: "monitoring.coreos.com"
endpoints: []
ports:
metrics:
scheme: http
name: http-metrics
port: 10251
protocol: TCP
serviceSelectorLabels:
- "component=kube-scheduler"
insecureSkipVerify: true
exporter-kubelets:
enabled: false
apiGroup: "monitoring.coreos.com"
serviceSelectorLabels:
- "k8s-app=kubelet"
insecureSkipVerify: true
## Set false when using GKE
##
https: true
exporter-kubernetes:
enabled: false
apiGroup: "monitoring.coreos.com"
ports:
metrics:
scheme: https
name: https
serviceSelectorLabels:
- "component=apiserver"
- "provider=kubernetes"
insecureSkipVerify: true
exporter-fluentd:
enabled: false
apiGroup: "monitoring.coreos.com"
ports:
metrics:
scheme: http
name: metric
serviceSelectorLabels:
- "app=fluentd"
insecureSkipVerify: true
exporter-node:
enabled: false
apiGroup: "monitoring.coreos.com"
image:
repository: rancher/prom-node-exporter
tag: v0.17.0
nodeSelectors: []
resources:
limits:
cpu: 200m
memory: 50Mi
requests:
cpu: 100m
memory: 30Mi
ports:
metrics:
port: 9100
collectors: {}
enabledHostNetwork: true
enabledHostPID: true
## Already exist ServiceAccount
##
serviceAccountName: ""
exporter-kube-state:
enabled: false
apiGroup: "monitoring.coreos.com"
image:
repository: rancher/coreos-kube-state-metrics
tag: v1.5.0
nodeSelectors: []
resources:
limits:
cpu: 100m
memory: 200Mi
requests:
cpu: 100m
memory: 130Mi
## Already exist ServiceAccount
##
serviceAccountName: ""
securityContext: {}
alertmanager:
enabled: false
apiGroup: "monitoring.coreos.com"
image:
repository: rancher/prom-alertmanager
tag: v0.16.1
nodeSelectors: []
resources:
core:
limits:
memory: 500Mi
cpu: 1000m
requests:
memory: 100Mi
cpu: 100m
config:
global:
resolve_timeout: 5m
route:
group_by: ['job']
group_wait: 30s
group_interval: 5m
repeat_interval: 12h
receiver: 'null'
routes:
- match:
alertname: DeadMansSwitch
receiver: 'null'
receivers:
- name: 'null'
persistence:
enabled: false
storageClass: ""
accessMode: "ReadWriteOnce"
size: 50Gi
## Already exist ServiceAccount
##
serviceAccountName: ""
securityContext:
runAsUser: 1000
runAsNonRoot: true
fsGroup: 2000
grafana:
enabled: false
level: cluster
apiGroup: "monitoring.coreos.com"
image:
repository: rancher/grafana-grafana
tag: 5.4.3
tool:
repository: rancher/prometheus-auth
tag: v0.2.0
proxy:
repository: rancher/nginx
tag: 1.15.8-alpine
nodeSelectors: []
resources:
inits:
limits:
memory: 50Mi
cpu: 50m
requests:
memory: 50Mi
cpu: 50m
core:
limits:
memory: 200Mi
cpu: 200m
requests:
memory: 100Mi
cpu: 100m
proxy:
limits:
memory: 100Mi
cpu: 100m
requests:
memory: 50Mi
cpu: 50m
persistence:
enabled: false
storageClass: ""
accessMode: "ReadWriteOnce"
size: 50Gi
## Already exist ServiceAccount
##
serviceAccountName: ""
prometheusDatasourceURL: "http://prometheus-operated:9090"
prometheus:
enabled: false
level: cluster
auth:
args:
- --proxy-url=http://localhost:9090
- --listen-address=$(POD_IP):9090
- --filter-reader-labels=prometheus
- --filter-reader-labels=prometheus_replica
env:
- name: POD_IP
valueFrom:
fieldRef:
fieldPath: status.podIP
apiGroup: "monitoring.coreos.com"
image:
repository: rancher/prom-prometheus
tag: v2.7.1
auth:
repository: rancher/prometheus-auth
tag: v0.2.0
proxy:
repository: rancher/nginx
tag: 1.15.8-alpine
nodeSelectors: []
resources:
core:
limits:
memory: 500Mi
cpu: 1000m
requests:
memory: 100Mi
cpu: 100m
proxy:
limits:
memory: 100Mi
cpu: 100m
requests:
memory: 50Mi
cpu: 50m
auth:
limits:
memory: 200Mi
cpu: 500m
requests:
memory: 100Mi
cpu: 100m
persistence:
enabled: false
storageClass: ""
accessMode: "ReadWriteOnce"
size: 50Gi
alertingEndpoints: []
secrets: []
## Already exist ServiceAccount
##
serviceAccountName: ""
serviceAccountNameOverride: ""
ruleNamespaceSelector: {}
ruleSelector:
matchExpressions: []
serviceMonitorNamespaceSelector: {}
serviceMonitorSelector:
matchExpressions: []
addtionalBindingClusterRoles: []
securityContext:
runAsUser: 1000
runAsNonRoot: true
fsGroup: 2000
sync:
mode: "remote"
path: "/api/v1/read"
target: ""
global:
systemDefaultRegistry: ""
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment