Repository navigation
kubernetes.config.config_exception.ConfigException: Invalid kube-config file. Expected key users in kube-config #236
Description
Activity
does
kubectlworks? can you share redacted kube config file content at~/.kube/config?apiVersion: v1
clusters:- cluster:
server: http://10.213.18.39:8080
name: test
contexts: - context:
cluster: test
user: test
name: test
Yes Kubectl command is working fine
Below the o/p of command
root@csp-central-ms-vm1839:~/REQUESTS# kubectl get pods
NAME READY STATUS RESTARTS AGE
csp.admin-portal-ui-346402271-qnuw8 1/1 Running 0 24d
csp.ams-2611059999-cypjx 1/1 Running 0
24d
- cluster:
- addedkind/bugCategorizes issue or PR as related to a bug.Categorizes issue or PR as related to a bug.
on May 30, 2017 - added a commit that references this issue
on Jun 5, 2017 I uploaded a PR that should fix this issue, could you test please?
I commented on your (merged) PR. I think it is in the right direction but needs more fixes. It may fix @sidd14491 issue (sidd14491 can you confirm?) but need to fix this for all cases where user is missing.
For verification which build I need to take.
Can you mention the build location from where I'll take the fixed version and tested my scenario..
Thanks.
SiddharthYou have to install the latest version from sources. The following commands will do:
git clone --recursive git@github.com:kubernetes-incubator/client-python.git cd client-python/kubernetes/base git checkout master cd ../.. python setup.py installThen you can execute an example script with your client config. The following command will load the default context of your kube.cfg:
python -m examples.example1@mbohlool before closing this PR I think that we must update the git submodule to a revision that includes all the fixes. What do you think?
- Definitely. Go for it.…On Jun 6, 2017 1:23 AM, "Sergi Almacellas Abellana" < ***@***.***> wrote: @mbohlool <https://github.com/mbohlool> before closing this PR I think that we must update the git submodule to a revision that includes all the fixes. What do you think? — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub <#236 (comment)>, or mute the thread <https://github.com/notifications/unsubscribe-auth/ABic4MI5MdfynXO765yZM8X_Kb9O1U_4ks5sBQyYgaJpZM4NnfuJ> .
I'm waiting for kubernetes-client/python-base#5 to be merged before updating submodules.
For now we should keep the issue open. Can you reopen please?
- added a commit that references this issue
on Jun 9, 2017 - added a commit that references this issue
on Jun 12, 2017 - Hi, I have one query, Is there any rest-api in kubernetes to upgrade the container build with specific on. Suppose that I want to upgrade from 212 to 214, but I want pass the 214 as a argument in rest call with specific pods BR/ Siddharth…On Fri, May 26, 2017 at 11:34 PM, Mehdy Bohlool ***@***.***> wrote: does kubectl works? can you share redacted kube config file content at ~/.kube/config? — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub <#236 (comment)>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AMar1IPl38MFYx0jy0n_qoXkRac3r8xIks5r9xQVgaJpZM4NnfuJ> .
@sidd14491 I don't see how your question is related to the current thread. Can you open a new issue please?
- Hi It's not related to current bug I am just asking you query is there any to do that ? BR? Siddharth…On Fri, Jun 16, 2017 at 12:41 PM, Sergi Almacellas Abellana < ***@***.***> wrote: @sidd14491 <https://github.com/sidd14491> I don't see how your question is related to the current thread. Can you open a new issue please? — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub <#236 (comment)>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AMar1AcZaL2gMFqc3CGLYcYBgQFVRI0Oks5sEiqsgaJpZM4NnfuJ> .
So please open a new issue for different questions....
of course this is closed.
- added a commit that references this issue
on Oct 7, 2022 - added a commit that references this issue
on Apr 1, 2024 - added a commit that references this issue
on Feb 4, 2026
After installing Kubernets package used the script to list of all pods.
But After running the script I am observing following error.
File "1.py", line 4, in
config.load_kube_config()
File "build/bdist.linux-x86_64/egg/kubernetes/config/kube_config.py", line 311, in load_kube_config
File "build/bdist.linux-x86_64/egg/kubernetes/config/kube_config.py", line 282, in _get_kube_config_loader_for_yaml_file
File "build/bdist.linux-x86_64/egg/kubernetes/config/kube_config.py", line 118, in init
File "build/bdist.linux-x86_64/egg/kubernetes/config/kube_config.py", line 134, in set_active_context
File "build/bdist.linux-x86_64/egg/kubernetes/config/kube_config.py", line 253, in getitem
kubernetes.config.config_exception.ConfigException: Invalid kube-config file. Expected key users in kube-config