Closed rubenrajkowski-nbcuni closed 3 years ago
I've tried updating protocol=http, and port=80 and get similar Error: getaddrinfo ENOTFOUND http
export KUBERNETES_SERVICE_HOST="https://{ACCOUNT_ID}.us-west-2.eks.amazonaws.com" export KUBERNETES_SERVICE_PORT="443"
https://github.com/godaddy/kubernetes-client/blob/de189a65fcf7cc5c3d711c7508e8beacbea4d444/examples/in-cluster-auth.js
const listK8Pods = async() => { try{ const pods = await client.api.v1.pods.get(); return pods.body.items.forEach((item) => { logger.accessLog.info('POD: '+item.metadata); return item.metadata; }); }catch(err){ throw err; } }; console.log('list pods: '+ listK8Pods());
Closing out this issue. I realized i need to use minikube or telepresence to connect to a remote cluster. thanks!
minikube
telepresence
I've tried updating protocol=http, and port=80 and get similar Error: getaddrinfo ENOTFOUND http
.zshrc file
example used
https://github.com/godaddy/kubernetes-client/blob/de189a65fcf7cc5c3d711c7508e8beacbea4d444/examples/in-cluster-auth.js
code example: