mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-24 04:06:03 +00:00
Merge pull request #4952 from rjnagal/kubectl
Add capacity information to 'kubectl describe minion'
This commit is contained in:
commit
93c0052263
@ -323,6 +323,12 @@ func (d *MinionDescriber) Describe(namespace, name string) (string, error) {
|
||||
c.Message)
|
||||
}
|
||||
}
|
||||
if len(minion.Spec.Capacity) > 0 {
|
||||
fmt.Fprintf(out, "Capacity:\n")
|
||||
for resource, value := range minion.Spec.Capacity {
|
||||
fmt.Fprintf(out, " %s:\t%s\n", resource, value.String())
|
||||
}
|
||||
}
|
||||
fmt.Fprintf(out, "Pods:\t(%d in total)\n", len(pods))
|
||||
for _, pod := range pods {
|
||||
if pod.Status.Host != name {
|
||||
|
Loading…
Reference in New Issue
Block a user