From c105c04b6b1ddb917c12eadacb26c252f44ddfad Mon Sep 17 00:00:00 2001 From: Jason Schwerberg Date: Sat, 15 Jun 2019 11:49:33 -0700 Subject: [PATCH] kubectl: add statefulset aliases (#7826) --- plugins/kubectl/README.md | 9 +++++++++ plugins/kubectl/kubectl.plugin.zsh | 10 ++++++++++ 2 files changed, 19 insertions(+) diff --git a/plugins/kubectl/README.md b/plugins/kubectl/README.md index 4541c7e92..c0db59362 100644 --- a/plugins/kubectl/README.md +++ b/plugins/kubectl/README.md @@ -96,3 +96,12 @@ plugins=(... kubectl) | kepvc | `kubectl edit pvc` | Edit pvcs from the default editor | | kdpvc | `kubectl describe pvc` | Descirbe all pvcs | | kdelpvc | `kubectl delete pvc` | Delete all pvcs matching passed arguments | +| | | | +| kgss | `kubectl get statefulset` | List the statefulsets in ps format | +| kgssw | `kgss --watch` | After getting the list of statefulsets, watch for changes | +| kgsswide| `kgss -o wide` | After getting the statefulsets, output in plain-text format with any additional information | +| kess | `kubectl edit statefulset` | Edit statefulset resource from the default editor | +| kdss | `kubectl describe statefulset` | Describe statefulset resource in detail | +| kdelss | `kubectl delete statefulset` | Delete the statefulset | +| ksss | `kubectl scale statefulset` | Scale a statefulset | +| krsss | `kubectl rollout status statefulset`| Check the rollout status of a deployment | diff --git a/plugins/kubectl/kubectl.plugin.zsh b/plugins/kubectl/kubectl.plugin.zsh index 5097732db..6c1696d5e 100644 --- a/plugins/kubectl/kubectl.plugin.zsh +++ b/plugins/kubectl/kubectl.plugin.zsh @@ -96,6 +96,16 @@ alias kgrs='kubectl get rs' alias krh='kubectl rollout history' alias kru='kubectl rollout undo' +# Statefulset management. +alias kgss='kubectl get statefulset' +alias kgssw='kgss --watch' +alias kgsswide='kgss -o wide' +alias kess='kubectl edit statefulset' +alias kdss='kubectl describe statefulset' +alias kdelss='kubectl delete statefulset' +alias ksss='kubectl scale statefulset' +alias krsss='kubectl rollout status statefulset' + # Port forwarding alias kpf="kubectl port-forward"