0.6.0
Support SSH local port forwarding to access a remote server. This allows to forward the traffic form local machine to SSH jump then SSH jump will forward the traffic to the remote server - #12
About SSH local port forwarding with kubectl ssh-jump
Suppose you have private & public SSH key on your side and you want to access a remote server (IP: 10.100.10.8
) using 3389
/TCP port which is not accessible directly but accessible via SSH jump, execute the plugin with options like this, at first:
- identity:
~/.ssh/id_rsa_k8s
- pubkey:
~/.ssh/id_rsa_k8s.pub
)
The command below allows to forward the traffic form local machine (localhost:13200
) to SSH jump then SSH jump will forward the traffic to the remote server (10.100.10.8:3389
).
$ kubectl ssh-jump sshjump \
-i ~/.ssh/id_rsa_k8s -p ~/.ssh/id_rsa_k8s.pub \
-a "-L 13200:10.100.10.8:3389"
sshjump
is the hostname for SSH jump Pod- The value for
--arg
or-a
should be in this format: "-L local_port:remote_address:remote_port"
Now, you're ready to access to the remote server at port 13200 at local machine.