kubectl tail with fzf to select label values
This commit is contained in:
parent
5b7533850f
commit
f17ac2dad4
1 changed files with 5 additions and 0 deletions
5
bin/ktail
Executable file
5
bin/ktail
Executable file
|
@ -0,0 +1,5 @@
|
|||
#!/bin/bash
|
||||
kubectl get pod --output json \
|
||||
| jq -r '[.items[].metadata.labels]|map(to_entries[]|(.key) + "=" + .value)|unique|.[]' \
|
||||
| fzf \
|
||||
| xargs kubectl tail "$@" -l
|
Loading…
Reference in a new issue