Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type IOStreamer ¶ added in v0.11.0
type IOStreamer struct { Streams Streams InputStream io.ReadCloser OutputStream io.Writer ErrorStream io.Writer Resp types.HijackedResponse }
An IOStreamer handles copying input to and output from streams to the connection.
func (*IOStreamer) Stream ¶ added in v0.11.0
func (h *IOStreamer) Stream(ctx context.Context) error
Stream handles setting up the IO and then begins streaming stdin/stdout to/from the hijacked connection, blocking until it is either done reading output, the user inputs the detach key sequence when in TTY mode, or when the given context is cancelled.
type In ¶
type In struct {
// contains filtered or unexported fields
}
In is an input stream used by the DockerCli to read user input
func (*In) CheckTty ¶
CheckTty checks if we are trying to attach to a container tty from a non-tty client input stream, and if so, returns an error.
func (*In) IsTerminal ¶
func (s *In) IsTerminal() bool
IsTerminal returns true if this stream is connected to a terminal
func (*In) SetRawTerminal ¶
SetRawTerminal sets raw mode on the input terminal
type Out ¶
type Out struct {
// contains filtered or unexported fields
}
Out is an output stream used by the DockerCli to write normal program output.
func (*Out) GetTtySize ¶
GetTtySize returns the height and width in characters of the tty
func (*Out) IsTerminal ¶
func (s *Out) IsTerminal() bool
IsTerminal returns true if this stream is connected to a terminal
func (*Out) SetRawTerminal ¶
SetRawTerminal sets raw mode on the input terminal