Skip to content

Instantly share code, notes, and snippets.

View corvofeng's full-sized avatar
Do You Want To Build A Snowman.

corvofeng corvofeng

Do You Want To Build A Snowman.
View GitHub Profile
@corvofeng
corvofeng / http_ssh_tunnel.go
Created May 26, 2022 12:58
SSH tunnel to forward http port
package main
// Forward from local port 8001 to remote port 9999, by ssh tunnel
import (
"fmt"
"io"
"log"
"net"
"net/http"
// main
/**
* A golang ssh server which supports vscode remote ssh plugin.
*
* ssh_config:
* Host upterm
* HostName 192.168.101.135
* Port 2224
*
* VSCode remote ssh plugin use this command to setup its server, and use dynamic port fowarding to connect to this server.