Chris G.
Chris G.

Reputation: 25964

How to access a node from kubectl

In this doc they use u@node$ to define that the command is done from a node in a cluster. But how do you get to the node from kubectl?

It is well described how to get to a pod u@pod$

Upvotes: 1

Views: 4307

Answers (2)

suren
suren

Reputation: 8776

On GKE you simply select your cluster and click on SSH button. If from the command line, then:

gcloud compute ssh NODE --zone ZONE

Upvotes: 3

dippynark
dippynark

Reputation: 3003

The apiserver can be used as a HTTP proxy (as described here) to hit endpoints on Nodes, but I assume you need an SSH session which won't help.

On GKE you can SSH into your nodes using gcloud as follows:

  • gcloud compute instances list
  • gcloud compute ssh <nodeName>

Upvotes: 4

Related Questions