Commit Graph

13 Commits

Author SHA1 Message Date
Mrunal Patel d284fdfaa3 Add Capabilities field to process.
Signed-off-by: Mrunal Patel <mrunalp@gmail.com>
2015-03-25 15:39:34 -04:00
Andrey Vagin 872663148e paranoia: Don't return -1 as PID in error cases
I have seen a few times, when kill() was called for this
value on error paths and nobody survived except the init process.

man 2 kill
If pid equals -1, then sig is sent to every process for which the call‐
ing  process  has  permission  to  send  signals,  except for process 1
(init), but see below.

Signed-off-by: Andrey Vagin <avagin@openvz.org>
2015-03-05 08:07:33 +03:00
Daniel, Dao Quang Minh 4ce8d97320 do not pass nil to genericError
currently genericError constructors require not-nil error to be able to read
its Error() message

Signed-off-by: Daniel, Dao Quang Minh <dqminh89@gmail.com>
2015-03-03 22:47:44 -05:00
Alexander Morozov 8d0b06257b Move tty configuration to Process
Now you need to call Process.NewConsole to setup console for process

Signed-off-by: Alexander Morozov <lk4d4@docker.com>
2015-02-25 15:04:43 -08:00
Andrey Vagin 94fb37f557 process: add Wait(), Signal() and Pid() methods
Currently we have a problem when buffers are used for std file
descriptors.  These buffers are filled from goroutines (Cmd.goroutine),
and we need to wait them to be sure that all data have been copied.

Signed-off-by: Andrew Vagin <avagin@openvz.org>
2015-02-23 23:40:41 +03:00
Michael Crosby 1edada52fd Move Cwd and User to Process
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2015-02-11 11:20:09 -08:00
Michael Crosby 0c1919c427 Refactor parent processes into types
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2015-02-11 11:20:09 -08:00
Michael Crosby 21bb5ccc4f Move environment configuration to Process
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2015-02-11 11:20:09 -08:00
Michael Crosby 5fc19e8db5 Rename Fs fields to fs
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2015-02-11 11:20:08 -08:00
Michael Crosby 8191d4d60f Refactory container interface
This removes a new unused methods from the container interface and types
parameters such as os.Signal and WaitStatus

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2015-01-31 20:51:12 -08:00
Andrey Vagin 76d395eff2 new-api: add Console to ProcessConfig
Add ability to execute a process with a specified terminal.

Signed-off-by: Andrey Vagin <avagin@openvz.org>
2015-01-15 18:22:47 +03:00
Andrey Vagin 540f44d3b2 process: use io.Reader instead of io.WriteCloser for standard fds
Could someone explain why we should close this fds? Usually users
cares about closing them or not.
For example exec.Cmd declares them as io.Reader.

Signed-off-by: Andrey Vagin <avagin@openvz.org>
2014-12-19 14:48:16 +03:00
Michael Crosby dbb515f01f Update api proposal
Move concepts into specific files for easy management
Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@docker.com> (github: crosbymichael)

Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@docker.com> (github: vmarmol)
2014-07-08 11:27:27 -07:00