Documentation
      ¶
    
    
  
    
  
    Index ¶
Constants ¶
Variables ¶
This section is empty.
Functions ¶
func ContainerIDs ¶
ContainerIDs asks the ids of the containers on the other hand and return them to the caller
Types ¶
type Connector ¶
type Connector struct {
	// contains filtered or unexported fields
}
    Connector defines the connection and interactions
func NewConnector ¶
NewConnector returns a new Connector
func (*Connector) Interaction ¶
Interaction returns the interactor corresponding to the specified ID. If the connection doesn't exist the method will wait for the specified timeout, returning when the connection is created or the timeout expires, whichever occurs first
func (*Connector) RemoveInteraction ¶
RemoveInteraction removes the session the inteactions map
func (*Connector) SessionIfAlive ¶
SessionIfAlive returns SessionInteractor or error
type LazyInitializer ¶
type LazyInitializer func() (SessionInteractor, error)
LazyInitializer defines the function that returns SessionInteractor
type LazySessionInteractor ¶
type LazySessionInteractor struct {
	// contains filtered or unexported fields
}
    LazySessionInteractor holds lazily initialized SessionInteractor
func (*LazySessionInteractor) Initialize ¶
func (l *LazySessionInteractor) Initialize() (SessionInteractor, error)
Initialize either returns either already initialized connection or returns the connection after initializing it
func (*LazySessionInteractor) SessionInteractor ¶
func (l *LazySessionInteractor) SessionInteractor() SessionInteractor
SessionInteractor returns either an initialized connection, or nil if it was never initialized
type Server ¶
type Server struct {
	// contains filtered or unexported fields
}
    Server waits for TCP client connections on serialOverLANPort, then once connected, attempts to negotiate an SSH connection to the attached client. The client is the ssh server.
func (*Server) Addr ¶
Addr returns the address of the underlying listener
func (*Server) Interaction ¶
Interaction returns the session interface for the given container. If the container cannot be found, this call will wait for the given timeout. id is ID of the container.
func (*Server) RemoveInteraction ¶
RemoveInteraction removes the session interface from underlying connector
func (*Server) Start ¶
Start starts the connector with given listener
type SessionInteractor ¶
type SessionInteractor interface {
	// Send specific signal
	Signal(signal ssh.Signal) error
	// Stdout stream
	Stdout() io.Reader
	// Stderr stream
	Stderr() io.Reader
	// Stdin stream
	Stdin() io.WriteCloser
	Close() error
	// Resize the terminal
	Resize(cols, rows, widthpx, heightpx uint32) error
	CloseStdin() error
	Ping() error
	Unblock() error
}
    SessionInteractor defines the interaction interface
      
      Source Files
      ¶
    
- connector.go
 - interactor.go
 - lazy.go
 - server.go