Commit graph

13 commits

Author SHA1 Message Date
Michael Crosby
3742ae3ec8 Add timeout flag for container start times
This currently depends on a runc PR:

https://github.com/opencontainers/runc/pull/703

We need this pr because we have to SIGKILL runc and the container root
dir will still be left around.

As for the containerd changes this adds a flag to containerd so that you
can configure the timeout without any more code changes.  It also adds
better handling in the error cases and will kill the containerd-shim and
runc ( as well as the user process if it exists ) if the timeout is hit.

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2016-04-05 13:38:49 -07:00
Tianon Gravi
13f03c3f7a Fix minor "deferred" typo
Signed-off-by: Andrew "Tianon" Page <admwiggin@gmail.com>
2016-04-02 10:28:05 -07:00
Michael Crosby
47f239706c Add no pivot root support
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2016-03-30 21:52:15 -07:00
Michael Crosby
6e4d5b385c Add runtimeArgs to pass to shim
This allows you to pass options like:

```bash
containerd --debug --runtime-args "--debug" --runtime-args
"--systemd-cgroup"
```

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2016-03-24 13:31:27 -07:00
John Howard
b044ff0f29 Refactor process.go for platform specific
Signed-off-by: John Howard <jhoward@microsoft.com>

Move process sorter to new file

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>

Sort containers by id

This will not be the most accurate sorting but atleast the list will be
consistent inbetween calls.

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>

Allow runtime to be configurable via daemon start

This allows people to pass an alternate name or location to the runtime
binary to start containers.

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>

Fix state output for containers

Return the proper state/status for a container by checking if the pid is
still alive.  Also fix the cleanup handling in the shim to make sure
containers are not left behind.

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>

Properly wait for container start

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2016-02-29 10:43:35 -08:00
John Howard
cdb5947f86 Supervisor compiles
Signed-off-by: John Howard <jhoward@microsoft.com>
2016-02-26 14:58:15 -08:00
Michael Crosby
4e05bf491a Remove eventloop package
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2016-02-19 13:21:21 -08:00
Michael Crosby
3dc59d565a Rename Events to task in supervisor
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2016-02-11 17:26:24 -08:00
Michael Crosby
d6bd304c92 Add labels for containers
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2016-02-11 13:44:25 -08:00
Michael Crosby
36eb83cb99 Move fifo creation to client
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2016-02-03 13:56:15 -08:00
Michael Crosby
fe38efda50 Add shim for reattach of processes
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>

Remove runtime files from containerd

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>

Update supervisor for orphaned containers

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>

Remove ctr/container.go back to rpc calls

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>

Add attach to loaded container

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>

Add monitor based on epoll for process exits

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>

Convert pids in containerd to string

This is so that we no longer care about linux or system level pids and
processes in containerd have user defined process id(pid) kinda like the
exec process ids that docker has today.

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>

Add reaper back to containerd

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>

Implement list containers with new process model

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>

Implement restore of processes

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>

Add NONBLOCK to exit fifo open

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>

Implement tty reattach

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>

Fix race in exit pipe creation

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>

Add delete to shim

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>

Update shim to use pid-file and not stdout

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2016-02-02 16:00:22 -08:00
Michael Crosby
7d4f74474e Add more metrics collection
Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
2015-12-18 16:54:02 -08:00
Alexander Morozov
69f8f566a2 Move supervisor to it's own package
It allows to keep main namespace cleaner

Signed-off-by: Alexander Morozov <lk4d4@docker.com>
2015-12-17 16:18:48 -08:00
Renamed from create.go (Browse further)