plugins

package
v0.0.0-...-1b9e8c6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 27, 2018 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ContainerPlugin

type ContainerPlugin interface {
	// PreCreate defines plugin point where receives an container create request, in this plugin point user
	// could change the container create body passed-in by http request body
	PreCreate(io.ReadCloser) (io.ReadCloser, error)

	// PreStart returns an array of priority and args which will pass to runc, the every priority
	// used to sort the pre start array that pass to runc, network plugin hook always has priority value 0.
	PreStart(interface{}) ([]int, [][]string, error)
}

ContainerPlugin defines places where a plugin will be triggered in container lifecycle

type DaemonPlugin

type DaemonPlugin interface {
	// PreStartHook is invoked by pouch daemon before real start, in this hook user could start dfget proxy or other
	// standalone process plugins
	PreStartHook() error

	// PreStopHook is invoked by pouch daemon before daemon process exit, not a promise if daemon is killed, in this
	// hook user could stop the process or plugin started by PreStartHook
	PreStopHook() error
}

DaemonPlugin defines places where a plugin will be triggered in pouchd lifecycle

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL