Skip to content

linux_amd64 "--kubeconfig" not working on v0.31.6 #2488

@ccieliu

Description

@ccieliu




Describe the bug

  1. upgrade from v0.31.5(deb) to v0.31.6(deb)
  2. "--kubeconfig config.xxxx" not working at v0.31.6
    k9s always using default kubeconfig file at ".kube/config"

To Reproduce
Steps to reproduce the behavior:

command:

test@nb10516:~/.kube$ k9s --kubeconfig config.aws -l debug

Expected behavior
when pass "--kubeconfig" to k9s command, k9s should to use correct the config file, rather than default kubeconfig.

Versions (please complete the following information):

  • OS:
x64(amd64)
PRETTY_NAME="Ubuntu 22.04.3 LTS"
NAME="Ubuntu"
VERSION_ID="22.04"
VERSION="22.04.3 LTS (Jammy Jellyfish)"
VERSION_CODENAME=jammy
ID=ubuntu
ID_LIKE=debian
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
UBUNTU_CODENAME=jammy
  • K9s:
test@nb10516:~/.kube$ k9s version
 ____  __.________       
|    |/ _/   __   \______
|      < \____    /  ___/
|    |  \   /    /\___ \ 
|____|__ \ /____//____  >
        \/            \/ 

Version:    v0.31.6
Commit:     a543f47319c0bdff16200a7ac40336b95ddfc823
Date:       2024-01-18T06:54:23Z
  • K8s: ANY

Additional context
"--kubeconfig" not work on Version: v0.31.6

3:54PM DBG No custom skin found. Using stock skin
3:54PM INF 🐶 K9s starting up...
3:54PM DBG Found existing context config: "/home/test/.local/share/k9s/clusters/private-new-cluster/private-new-context/config.yaml"
3:54PM DBG Active Context "private-new-context"
3:54PM INF ✅ Kubernetes connectivity
3:54PM DBG No custom skin found. Using stock skin
3:54PM DBG Factory START with ns `"testing-map-management"
3:54PM DBG Fetching latest k9s rev...
3:54PM DBG K9s latest rev: "v0.31.6"
3:54PM DBG No custom skin found. Using stock skin


test@nb10516:~/.kube$ k9s --kubeconfig config.aws -l debug

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions