summaryrefslogtreecommitdiff
path: root/pkg/domain/entities/containers.go
diff options
context:
space:
mode:
authorBrent Baude <bbaude@redhat.com>2020-04-03 14:56:10 -0500
committerBrent Baude <bbaude@redhat.com>2020-04-05 15:54:51 -0500
commit4d895dcb5472da19b886ca1662182556242fe5d4 (patch)
tree13779856398cac75d3538e70d06e3a39470d1fef /pkg/domain/entities/containers.go
parentf7dffedeb610df662e69915fcff1bb37986baf55 (diff)
downloadpodman-4d895dcb5472da19b886ca1662182556242fe5d4.tar.gz
podman-4d895dcb5472da19b886ca1662182556242fe5d4.tar.bz2
podman-4d895dcb5472da19b886ca1662182556242fe5d4.zip
v2podman attach and exec
add the ability to attach to a running container. the tunnel side of this is not enabled yet as we have work on the endpoints and plumbing to do yet. add the ability to exec a command in a running container. the tunnel side is also being deferred for same reason. Signed-off-by: Brent Baude <bbaude@redhat.com>
Diffstat (limited to 'pkg/domain/entities/containers.go')
-rw-r--r--pkg/domain/entities/containers.go29
1 files changed, 29 insertions, 0 deletions
diff --git a/pkg/domain/entities/containers.go b/pkg/domain/entities/containers.go
index 74b23cd71..cf907eb1b 100644
--- a/pkg/domain/entities/containers.go
+++ b/pkg/domain/entities/containers.go
@@ -2,6 +2,7 @@ package entities
import (
"io"
+ "os"
"time"
"github.com/containers/libpod/libpod/define"
@@ -157,3 +158,31 @@ type RestoreReport struct {
type ContainerCreateReport struct {
Id string
}
+
+// AttachOptions describes the cli and other values
+// needed to perform an attach
+type AttachOptions struct {
+ DetachKeys string
+ Latest bool
+ NoStdin bool
+ SigProxy bool
+ Stdin *os.File
+ Stdout *os.File
+ Stderr *os.File
+}
+
+// ExecOptions describes the cli values to exec into
+// a container
+type ExecOptions struct {
+ Cmd []string
+ DetachKeys string
+ Envs map[string]string
+ Interactive bool
+ Latest bool
+ PreserveFDs uint
+ Privileged bool
+ Streams define.AttachStreams
+ Tty bool
+ User string
+ WorkDir string
+}