Files
troubleshoot/examples/preflight/host/disk-usage.yaml
Andrew Reed fe4db40b43 Move host preflights examples into separate directory
Add all supported analyzers to host preflight sample.
Don't log transient errors waiting for TCP connection.
Begin human stdout results on new line after spinner.
2021-02-15 22:46:12 +00:00

34 lines
1.1 KiB
YAML

apiVersion: troubleshoot.sh/v1beta2
kind: HostPreflight
metadata:
name: diskUsage
spec:
collectors:
- diskUsage:
collectorName: ephemeral
path: /var/lib/kubelet
analyzers:
- diskUsage:
collectorName: ephemeral
outcomes:
- fail:
when: "total < 20Gi"
message: /var/lib/kubelet has less than 20Gi of total space
- fail:
when: "available < 10Gi"
message: /var/lib/kubelet has less than 10Gi of disk space available
- fail:
when: "used/total > 70%"
message: /var/lib/kubelet is more than 70% full
- warn:
when: "total < 40Gi"
message: /var/lib/kubelet has less than 40Gi of total space
- warn:
when: "used/total > 60%"
message: /var/lib/kubelet is more than 60% full
- pass:
when: "available/total >= 90%"
message: /var/lib/kubelet has more than 90% available
- pass:
message: /var/lib/kubelet has sufficient disk space available