kubectl/cheatsheet - add command for sorting events (#7519)

- add a command to "List Events sorted by timestamp"

workaround for #29838
This commit is contained in:
Paweł Prażak
2018-02-26 16:45:44 +01:00
committed by k8s-ci-robot
parent 75aeaa3ddb
commit 0955d6be90
+3
View File
@@ -136,6 +136,9 @@ $ JSONPATH='{range .items[*]}{@.metadata.name}:{range @.status.conditions[*]}{@.
# List all Secrets currently in use by a pod
$ kubectl get pods -o json | jq '.items[].spec.containers[].env[]?.valueFrom.secretKeyRef.name' | grep -v null | sort | uniq
# List Events sorted by timestamp
$ kubectl get events --sort-by=.metadata.creationTimestamp
```
## Updating Resources