Documentation ¶ Index ¶ type Tunnel func New(user string, port int, addrs []string) *Tunnel func (t *Tunnel) Connect() ([]string, error) Constants ¶ This section is empty. Variables ¶ This section is empty. Functions ¶ This section is empty. Types ¶ type Tunnel ¶ type Tunnel struct { // contains filtered or unexported fields } Tunnel holds data needed to create one ssh tunnel per host for port forwarding. func New ¶ func New(user string, port int, addrs []string) *Tunnel New creates a new Tunnel func (*Tunnel) Connect ¶ func (t *Tunnel) Connect() ([]string, error) Connect creates an ssh tunnel for each address passed in. It also creates a dns lookup for the local net.DefaultResolver so that hostname resolves to the localhost address of the ssh tunnel. Source Files ¶ View all Source files tunnel.go Click to show internal directories. Click to hide internal directories.