runtime

package
v0.5.1 Latest Latest
Warning

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

Go to latest
Published: May 4, 2015 License: MIT Imports: 16 Imported by: 12

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func EC2PublicHostname

func EC2PublicHostname() (string, error)

func GetEndpoint

func GetEndpoint() string

Types

type ContainerEvent

type ContainerEvent struct {
	Status              string
	Container           *docker.Container
	ServiceRegistration *registry.ServiceRegistration
}

type ServiceRuntime

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

func NewServiceRuntime

func NewServiceRuntime(serviceRegistry *registry.ServiceRegistry, dns, hostIP string) *ServiceRuntime

func (*ServiceRuntime) EnvFor

func (s *ServiceRuntime) EnvFor(container *docker.Container) map[string]string

func (*ServiceRuntime) GetImageByName

func (s *ServiceRuntime) GetImageByName(img string) (*docker.APIImages, error)

func (*ServiceRuntime) InspectContainer

func (s *ServiceRuntime) InspectContainer(id string) (*docker.Container, error)

func (*ServiceRuntime) InspectImage

func (s *ServiceRuntime) InspectImage(image string) (*docker.Image, error)

func (*ServiceRuntime) InstanceCount

func (s *ServiceRuntime) InstanceCount(app, versionId string) (int, error)

func (*ServiceRuntime) ManagedContainers

func (s *ServiceRuntime) ManagedContainers() ([]*docker.Container, error)

func (*ServiceRuntime) NextInstanceSlot

func (s *ServiceRuntime) NextInstanceSlot(app, versionId string) (int, error)

func (*ServiceRuntime) Ping

func (s *ServiceRuntime) Ping() error

func (*ServiceRuntime) PullImage

func (s *ServiceRuntime) PullImage(version, id string) (*docker.Image, error)

func (*ServiceRuntime) RegisterAll

func (s *ServiceRuntime) RegisterAll(env, pool, hostIP string) ([]*registry.ServiceRegistration, error)

func (*ServiceRuntime) RegisterEvents

func (s *ServiceRuntime) RegisterEvents(env, pool, hostIP string, listener chan ContainerEvent) error

RegisterEvents monitors the docker daemon for events, and returns those that require registration action over the listener chan.

func (*ServiceRuntime) RunCommand

func (s *ServiceRuntime) RunCommand(env string, appCfg *config.AppConfig, cmd []string) (*docker.Container, error)

func (*ServiceRuntime) Start

func (s *ServiceRuntime) Start(env, pool string, appCfg *config.AppConfig) (*docker.Container, error)

func (*ServiceRuntime) StartIfNotRunning

func (s *ServiceRuntime) StartIfNotRunning(env, pool string, appCfg *config.AppConfig) (bool, *docker.Container, error)

NOTE: UNUSED

func (*ServiceRuntime) StartInteractive

func (s *ServiceRuntime) StartInteractive(env, pool string, appCfg *config.AppConfig) error

func (*ServiceRuntime) Stop

func (s *ServiceRuntime) Stop(appCfg *config.AppConfig) error

func (*ServiceRuntime) StopAll

func (s *ServiceRuntime) StopAll(env string) error

func (*ServiceRuntime) StopAllButCurrentVersion

func (s *ServiceRuntime) StopAllButCurrentVersion(appCfg *config.AppConfig) error

func (*ServiceRuntime) StopAllButLatest

func (s *ServiceRuntime) StopAllButLatest(env string, stopCutoff int64) error

func (*ServiceRuntime) StopAllButLatestService

func (s *ServiceRuntime) StopAllButLatestService(name string, stopCutoff int64) error

func (*ServiceRuntime) StopAllMatching

func (s *ServiceRuntime) StopAllMatching(name string) error

func (*ServiceRuntime) StopOldVersion

func (s *ServiceRuntime) StopOldVersion(appCfg *config.AppConfig, limit int) error

func (*ServiceRuntime) UnRegisterAll

func (s *ServiceRuntime) UnRegisterAll(env, pool, hostIP string) ([]*docker.Container, error)

Jump to

Keyboard shortcuts

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