K9s: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
|||
| Line 1: | Line 1: | ||
{|class='wikitable | {|class='wikitable' | ||
|valign='top' style='width:50%'| | |valign='top' style='width:50%'| | ||
<syntaxhighlight | <syntaxhighlight lang='bash'> | ||
brew install derailed/k9s/k9s | brew install derailed/k9s/k9s | ||
brew uninstall derailed/k9s/k9s | brew uninstall derailed/k9s/k9s | ||
| Line 7: | Line 7: | ||
|valign='top' style='width:50%'| | |valign='top' style='width:50%'| | ||
<syntaxhighlight | <syntaxhighlight lang='bash'> | ||
sudo snap install k9s | sudo snap install k9s | ||
sudo snap remove k9s | sudo snap remove k9s | ||
| Line 14: | Line 14: | ||
|- | |- | ||
|valign='top' colspan='2'| | |valign='top' colspan='2'| | ||
<syntaxhighlight | <syntaxhighlight lang='bash'> | ||
cat <<-'EXE'|sudo bash | cat <<-'EXE'|sudo bash | ||
K9S_PLATFORM="$(uname -s)_$(dpkg --print-architecture)" | K9S_PLATFORM="$(uname -s)_$(dpkg --print-architecture)" | ||
| Line 28: | Line 28: | ||
==Playground== | ==Playground== | ||
{|class='wikitable mw-collapsible | {|class='wikitable mw-collapsible' | ||
!scope='col' style='text-align:left' colspan='2'| | !scope='col' style='text-align:left' colspan='2'| | ||
Playground | Playground | ||
|- | |- | ||
|valign='top' style='width:50%'| | |valign='top' style='width:50%'| | ||
<syntaxhighlight | <syntaxhighlight lang='bash'> | ||
k9s --kubeconfig ${HOME}/.kube/shahed-aa-kubeconfig.yaml -c ctx | k9s --kubeconfig ${HOME}/.kube/shahed-aa-kubeconfig.yaml -c ctx | ||
k9s --kubeconfig ${HOME}/.kube/shahed-aa-kubeconfig.yaml -c ns | k9s --kubeconfig ${HOME}/.kube/shahed-aa-kubeconfig.yaml -c ns | ||
| Line 41: | Line 41: | ||
|valign='top' style='width:50%'| | |valign='top' style='width:50%'| | ||
<syntaxhighlight | <syntaxhighlight lang='bash'> | ||
export KUBECONFIG=${HOME}/.kube/shahed-aa-kubeconfig.yaml | export KUBECONFIG=${HOME}/.kube/shahed-aa-kubeconfig.yaml | ||
k9s -c ns | k9s -c ns | ||
| Line 49: | Line 49: | ||
|- | |- | ||
|valign='top'| | |valign='top'| | ||
<syntaxhighlight | <syntaxhighlight lang='bash'> | ||
k9s --context shahed-aa -n shahed-wiki-mediawiki -c pod | k9s --context shahed-aa -n shahed-wiki-mediawiki -c pod | ||
k9s --context shahed-aa -n shahed-wiki-mediawiki -c ing | k9s --context shahed-aa -n shahed-wiki-mediawiki -c ing | ||
| Line 59: | Line 59: | ||
|valign='top'| | |valign='top'| | ||
<syntaxhighlight | <syntaxhighlight lang='bash'> | ||
k9s -n shahed-wiki-mediawiki -c pod | k9s -n shahed-wiki-mediawiki -c pod | ||
k9s -n shahed-wiki-mediawiki -c ing | k9s -n shahed-wiki-mediawiki -c ing | ||
| Line 69: | Line 69: | ||
|- | |- | ||
|valign='top'| | |valign='top'| | ||
<syntaxhighlight | <syntaxhighlight lang='bash'> | ||
k9s help | k9s help | ||
k9s info | k9s info | ||
| Line 76: | Line 76: | ||
|valign='top'| | |valign='top'| | ||
<syntaxhighlight | <syntaxhighlight lang='bash'> | ||
export KUBECONFIG=${HOME}/.kube/shahed-aa-kubeconfig.yaml | export KUBECONFIG=${HOME}/.kube/shahed-aa-kubeconfig.yaml | ||
kubectl config view -o=yaml|yq '.contexts[0].name' | kubectl config view -o=yaml|yq '.contexts[0].name' | ||
| Line 84: | Line 84: | ||
==References== | ==References== | ||
{|class='wikitable mw-collapsible | {|class='wikitable mw-collapsible' | ||
!scope='col' style='text-align:left' colspan='3'| | !scope='col' style='text-align:left' colspan='3'| | ||
References | References | ||
Latest revision as of 05:49, 19 January 2026
brew install derailed/k9s/k9s
brew uninstall derailed/k9s/k9s
|
sudo snap install k9s
sudo snap remove k9s
|
cat <<-'EXE'|sudo bash
K9S_PLATFORM="$(uname -s)_$(dpkg --print-architecture)"
K9S_BINARY="$(echo "k9s_${K9S_PLATFORM}.deb"|tr '[:upper:]' '[:lower:]')"
K9S_VERSION="$(curl -s https://api.github.com/repos/derailed/k9s/releases/latest | grep -Po '"tag_name": "v\K[^"]*')"
curl -fsSLo "${K9S_BINARY}" "https://github.com/derailed/k9s/releases/download/v${K9S_VERSION}/${K9S_BINARY}"
dpkg -i "${K9S_BINARY}"
rm "${K9S_BINARY}"
apt-get install -f
EXE
| |
Playground
|
Playground | |
|---|---|
k9s --kubeconfig ${HOME}/.kube/shahed-aa-kubeconfig.yaml -c ctx
k9s --kubeconfig ${HOME}/.kube/shahed-aa-kubeconfig.yaml -c ns
k9s --kubeconfig ${HOME}/.kube/shahed-aa-kubeconfig.yaml -A
k9s --kubeconfig ${HOME}/.kube/shahed-aa-kubeconfig.yaml
|
export KUBECONFIG=${HOME}/.kube/shahed-aa-kubeconfig.yaml
k9s -c ns
k9s -A
k9s
|
k9s --context shahed-aa -n shahed-wiki-mediawiki -c pod
k9s --context shahed-aa -n shahed-wiki-mediawiki -c ing
k9s --context shahed-aa -n shahed-wiki-mediawiki
k9s --context shahed-aa -c ns
k9s --context shahed-aa -A
k9s --context shahed-aa
|
k9s -n shahed-wiki-mediawiki -c pod
k9s -n shahed-wiki-mediawiki -c ing
k9s -n shahed-wiki-mediawiki
k9s -c ns
k9s -A
k9s
|
k9s help
k9s info
k9s
|
export KUBECONFIG=${HOME}/.kube/shahed-aa-kubeconfig.yaml
kubectl config view -o=yaml|yq '.contexts[0].name'
kubectl config get-contexts
|
References
|
References | ||
|---|---|---|