diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2019-01-13 09:34:33 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-01-13 09:34:33 -0800 |
commit | 140ae25c4d0c7ba89a0bb7ae16f81f90d20be535 (patch) | |
tree | a5e30854d0669694556fdde8de43e00d30176d9c /libpod/container_api.go | |
parent | 9ada9722ecba373b317e1ab3e9adf716fc777d8d (diff) | |
parent | 43c6da22b976b6050f86dca50564a4c2b08caee0 (diff) | |
download | podman-140ae25c4d0c7ba89a0bb7ae16f81f90d20be535.tar.gz podman-140ae25c4d0c7ba89a0bb7ae16f81f90d20be535.tar.bz2 podman-140ae25c4d0c7ba89a0bb7ae16f81f90d20be535.zip |
Merge pull request #2141 from baude/remotetag
Add darwin support for remote-client
Diffstat (limited to 'libpod/container_api.go')
-rw-r--r-- | libpod/container_api.go | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/libpod/container_api.go b/libpod/container_api.go index 4eaf737b0..149867759 100644 --- a/libpod/container_api.go +++ b/libpod/container_api.go @@ -3,6 +3,7 @@ package libpod import ( "context" "fmt" + "io" "io/ioutil" "os" "strconv" @@ -413,6 +414,25 @@ func (c *Container) Exec(tty, privileged bool, env, cmd []string, user, workDir return waitErr } +// AttachStreams contains streams that will be attached to the container +type AttachStreams struct { + // OutputStream will be attached to container's STDOUT + OutputStream io.WriteCloser + // ErrorStream will be attached to container's STDERR + ErrorStream io.WriteCloser + // InputStream will be attached to container's STDIN + InputStream io.Reader + // AttachOutput is whether to attach to STDOUT + // If false, stdout will not be attached + AttachOutput bool + // AttachError is whether to attach to STDERR + // If false, stdout will not be attached + AttachError bool + // AttachInput is whether to attach to STDIN + // If false, stdout will not be attached + AttachInput bool +} + // Attach attaches to a container func (c *Container) Attach(streams *AttachStreams, keys string, resize <-chan remotecommand.TerminalSize) error { if !c.batched { |