feat: plugin to list all resources by namespace (#3619)
* Plugin to list all resources by namespace (closes #3618) * add get-all-namespace-resources.yaml plugin to plugins tablemine
parent
e762cc6d90
commit
b97885ce0c
|
|
@ -14,6 +14,7 @@ Following is an example of some plugin files in this directory. Other files are
|
|||
| dive.yaml | Dive image layers | containers | d | [Dive](https://github.com/wagoodman/dive) |
|
||||
| dup.yaml | Duplicate, edit and Debug resources | all | Shift-d/e/v | [dup](https://github.com/vash/dup) |
|
||||
| external-secrets.yaml | Refresh external/push-secrets | externalsecrets/pushsecrets | Shift-R | [External Secrets](https://external-secrets.io) |
|
||||
| get-all-namespace-resources.yaml | List all namespace resources (using standard kubectl) | all | m | [kubectl](https://kubernetes.io/docs/tasks/tools/) |
|
||||
| get-all.yaml | get all resources in a namespace | all | g | [Krew](https://krew.sigs.k8s.io/), [ketall](https://github.com/corneliusweig/ketall/) |
|
||||
| helm-diff.yaml | Diff with previous revision / current revision | helm/history | Shift-D/Q | [helm-diff](https://github.com/databus23/helm-diff) |
|
||||
| job-suspend.yaml | Suspends a running cronjob | cronjobs | Ctrl-s | |
|
||||
|
|
|
|||
|
|
@ -0,0 +1,47 @@
|
|||
plugins:
|
||||
get-all-resources-by-selected-namespace:
|
||||
shortCut: m
|
||||
confirm: false
|
||||
description: List all resources of the selected namespace
|
||||
scopes:
|
||||
- namespaces
|
||||
command: sh
|
||||
background: false
|
||||
args:
|
||||
- -c
|
||||
- 'for r in $(kubectl api-resources --verbs=list --namespaced -o name); do out=$(kubectl get --ignore-not-found --show-kind -n $NAME $r 2>/dev/null); if [ -n "$out" ]; then echo "$out"; echo ""; fi; done | less'
|
||||
get-all-resources-in-current-namespace:
|
||||
shortCut: m
|
||||
confirm: false
|
||||
description: List all resources of the current namespace
|
||||
scopes:
|
||||
- configmaps
|
||||
- controllerrevisions
|
||||
- daemonsets
|
||||
- deployments
|
||||
- endpoints
|
||||
- endpointslices
|
||||
- events
|
||||
- horizontalpodautoscalers
|
||||
- ingresses
|
||||
- jobs
|
||||
- leases
|
||||
- limitranges
|
||||
- networkpolicies
|
||||
- persistentvolumeclaims
|
||||
- poddisruptionbudgets
|
||||
- pods
|
||||
- replicasets
|
||||
- replicationcontrollers
|
||||
- resourcequotas
|
||||
- rolebindings
|
||||
- roles
|
||||
- secrets
|
||||
- serviceaccounts
|
||||
- services
|
||||
- statefulsets
|
||||
command: sh
|
||||
background: false
|
||||
args:
|
||||
- -c
|
||||
- 'for r in $(kubectl api-resources --verbs=list --namespaced -o name); do out=$(kubectl get --ignore-not-found --show-kind -n $NAMESPACE $r 2>/dev/null); if [ -n "$out" ]; then echo "$out"; echo ""; fi; done | less'
|
||||
Loading…
Reference in New Issue