resource_pool

package
v0.333.2-candidate Latest Latest
Warning

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

Go to latest
Published: Aug 26, 2016 License: Apache-2.0 Imports: 29 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrUnknownRootFSProvider = errors.New("unknown rootfs provider")
)

Functions

This section is empty.

Types

type FilterProvider

type FilterProvider interface {
	ProvideFilter(containerId string) network.Filter
}

type LinuxResourcePool

type LinuxResourcePool struct {
	// contains filtered or unexported fields
}

func New

func New(
	logger lager.Logger,
	binPath, depotPath string,
	sysconfig sysconfig.Config,
	rootFSProvider RootFSProvider,
	rootFSCleaner RootFSCleaner,
	mappingList rootfs_provider.MappingList,
	externalIP net.IP,
	mtu int,
	subnetPool SubnetPool,
	bridges bridgemgr.BridgeManager,
	iptablesMgr linux_container.IPTablesManager,
	filterProvider FilterProvider,
	defaultChain iptables.Chain,
	portPool linux_container.PortPool,
	denyNetworks, allowNetworks []string,
	runner command_runner.CommandRunner,
	quotaManager linux_container.QuotaManager,
	currentContainerVersion semver.Version,
	mkdirChowner MkdirChowner,
) *LinuxResourcePool

func (*LinuxResourcePool) Acquire

func (*LinuxResourcePool) MaxContainers

func (p *LinuxResourcePool) MaxContainers() int

func (*LinuxResourcePool) Prune

func (p *LinuxResourcePool) Prune(keep map[string]bool) error

func (*LinuxResourcePool) Release

func (*LinuxResourcePool) Restore

func (*LinuxResourcePool) Setup

func (p *LinuxResourcePool) Setup() error

type MkdirChowner

type MkdirChowner interface {
	MkdirChown(path string, uid, gid uint32, mode os.FileMode) error
}

type Remover

type Remover interface {
	Remove(id layercake.ID) error
}

type RootFSCleaner

type RootFSCleaner interface {
	Clean(log lager.Logger, path string) error
}

type RootFSProvider

type RootFSProvider interface {
	Create(log lager.Logger, id string, spec rootfs_provider.Spec) (mountpoint string, envvar []string, err error)
	Destroy(log lager.Logger, id string) error
	GC(log lager.Logger) error
}

type SubnetPool

type SubnetPool interface {
	Acquire(subnet subnets.SubnetSelector, ip subnets.IPSelector, logger lager.Logger) (*linux_backend.Network, error)
	Release(network *linux_backend.Network, logger lager.Logger) error
	Remove(network *linux_backend.Network, logger lager.Logger) error
	Capacity() int
}

Directories

Path Synopsis
This file was generated by counterfeiter
This file was generated by counterfeiter
This file was generated by counterfeiter
This file was generated by counterfeiter
This file was generated by counterfeiter
This file was generated by counterfeiter
This file was generated by counterfeiter
This file was generated by counterfeiter
This file was generated by counterfeiter
This file was generated by counterfeiter
This file was generated by counterfeiter
This file was generated by counterfeiter

Jump to

Keyboard shortcuts

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