package restartmanager

import "github.com/docker/cli/components/engine/restartmanager"

Index

Variables

var ErrRestartCanceled = errors.New("restart canceled")

ErrRestartCanceled is returned when the restart manager has been canceled and will no longer restart the container.

Types

type RestartManager

type RestartManager interface {
	Cancel() error
	ShouldRestart(exitCode uint32, hasBeenManuallyStopped bool, executionDuration time.Duration) (bool, chan error, error)
}

RestartManager defines object that controls container restarting rules.

func New

func New(policy container.RestartPolicy, restartCount int) RestartManager

New returns a new restartManager based on a policy.

Source Files

restartmanager.go

Version
v17.12.0-ce+incompatible
Published
Dec 27, 2017
Platform
js/wasm
Imports
5 packages
Last checked
3 hours ago

Tools for package owners.