Skip to content

Instantly share code, notes, and snippets.

@scemama
Last active August 29, 2015 14:14
Show Gist options
  • Save scemama/fcf709b2d4eec693f2f9 to your computer and use it in GitHub Desktop.
Save scemama/fcf709b2d4eec693f2f9 to your computer and use it in GitHub Desktop.
SSH connect through a gateway
# In .ssh/config:
Host target.host.domain target
User username_on_target
HostName target.host.domain
ProxyCommand ssh [email protected] nc %h %p
# The `nc` command should be installed on the gateway.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment