2015-12-18 00:07:04 +00:00
|
|
|
package supervisor
|
2015-11-05 23:29:53 +00:00
|
|
|
|
|
|
|
import "errors"
|
|
|
|
|
|
|
|
var (
|
2016-06-03 22:00:49 +00:00
|
|
|
// ErrContainerNotFound is returned when the container ID passed
|
|
|
|
// for a given operation is invalid
|
|
|
|
ErrContainerNotFound = errors.New("containerd: container not found")
|
|
|
|
// ErrProcessNotFound is returned when the process ID passed for
|
|
|
|
// a given operation is invalid
|
|
|
|
ErrProcessNotFound = errors.New("containerd: process not found for container")
|
|
|
|
// ErrUnknownContainerStatus is returned when the container status
|
|
|
|
// cannot be determined
|
2015-11-12 21:40:23 +00:00
|
|
|
ErrUnknownContainerStatus = errors.New("containerd: unknown container status ")
|
2016-06-03 22:00:49 +00:00
|
|
|
// ErrUnknownTask is returned when an unknown Task type is
|
|
|
|
// scheduled (should never happen).
|
|
|
|
ErrUnknownTask = errors.New("containerd: unknown task type")
|
2015-11-05 23:29:53 +00:00
|
|
|
|
|
|
|
// Internal errors
|
2015-12-01 20:00:11 +00:00
|
|
|
errShutdown = errors.New("containerd: supervisor is shutdown")
|
|
|
|
errRootNotAbs = errors.New("containerd: rootfs path is not an absolute path")
|
|
|
|
errNoContainerForPid = errors.New("containerd: pid not registered for any container")
|
2015-12-01 18:55:13 +00:00
|
|
|
// internal error where the handler will defer to another for the final response
|
|
|
|
//
|
|
|
|
// TODO: we could probably do a typed error with another error channel for this to make it
|
|
|
|
// less like magic
|
2016-04-02 17:28:05 +00:00
|
|
|
errDeferredResponse = errors.New("containerd: deferred response")
|
2015-11-05 23:29:53 +00:00
|
|
|
)
|