Skip to content

Instantly share code, notes, and snippets.

@bagwanpankaj
Forked from superchink/show
Created July 22, 2011 05:49
Show Gist options
  • Save bagwanpankaj/1098956 to your computer and use it in GitHub Desktop.
Save bagwanpankaj/1098956 to your computer and use it in GitHub Desktop.
This does something essentially equivalent to showoff.io if you have a publicly facing server...
# Usage: show <local-port> <subdomain>
function show() {
DOMAIN=".webhostology.com"
REMOTE="$2$DOMAIN"
ssh -tR 8080:127.0.0.1:$1 vps "sudo ssh -Nl \$USER -L $REMOTE:80:127.0.0.1:8080 localhost"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment