You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fromkubernetesimportclient, config# Configs can be set in Configuration class directly or using helper utilityconfig.load_kube_config()
v1=client.CoreV1Api()
print("Listing pods with their IPs:")
ret=v1.list_namespaced_pod(namespace="default", watch=False)
foriinret.items:
print("%s\t%s\t%s"% (i.status.pod_ip, i.metadata.namespace, i.metadata.name))
You'll get an error:
'ERROR:root:exec: process returned 1. Error: name must be specified. Hint: update kubectl in case you are using a version older than v1.20.0
Usage:
gardenlogin get-client-certificate [flags
]
Flags:
...
Anything else we need to know?:
Environment:
Kubernetes version (kubectl version):
OS (e.g., MacOS 10.13.6):
Python version (python --version)
Python client version (pip list | grep kubernetes)
The text was updated successfully, but these errors were encountered:
What happened (please include outputs or screenshots):
#2298 / #2303 implemented the
provideClusterInfo
.It misses this part (from https://kubernetes.io/docs/reference/config-api/client-authentication.v1/#client-authentication-k8s-io-v1-Cluster):
What you expected to happen:
client.authentication.k8s.io/exec
extension is set toExecCredentialSpec.Cluster.config
so that gardenlogin can use itHow to reproduce it (as minimally and precisely as possible):
Unfortunately I only know how to reproduce it with a Gardener Kubernetes setup.
Setup the KUBECONFIG environment:
gardenctl target --garden xxx --project xxx --shoot xxx
eval $(gardenctl kubectl-env zsh)
-> this sets KUBECONFIG to a file, that looks like this: https://github.com/gardener/gardenlogin/blob/42df32af80451062f81c015c5e89a109c821e463/README.md?plain=1#L86-L99Then run following script:
You'll get an error:
Anything else we need to know?:
Environment:
kubectl version
):python --version
)pip list | grep kubernetes
)The text was updated successfully, but these errors were encountered: