示例#1
0
func (r *streamingRuntime) Attach(containerID string, in io.Reader, out, errw io.WriteCloser, tty bool, resize <-chan term.Size) error {
	_, err := checkContainerStatus(r.client, containerID)
	if err != nil {
		return err
	}

	return dockertools.AttachContainer(r.client, containerID, in, out, errw, tty, resize)
}
示例#2
0
// TODO: implement the methods in this file.
func (ds *dockerService) AttachContainer(id kubecontainer.ContainerID, stdin io.Reader, stdout, stderr io.WriteCloser, tty bool, resize <-chan term.Size) (err error) {
	return dockertools.AttachContainer(ds.client, id, stdin, stdout, stderr, tty, resize)
}