container

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Dec 5, 2017 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DockerLookup

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

DockerLookup implements the lookup interface for Docker

func NewDockerLookup

func NewDockerLookup(dockerHost string) (*DockerLookup, error)

NewDockerLookup creates a new lookup service given a docker host

func (*DockerLookup) Lookup

func (c *DockerLookup) Lookup(id string) (dockerLogger.Info, error)

Lookup takes a containerID and returns info needed by a logger. These lookups are cached for 30 minutes

type Lookup

type Lookup interface {
	Lookup(containerID string) (dockerLogger.Info, error)
}

Lookup is an interface for looking up container info given a containerID

type MockLookup

type MockLookup struct {
	Store map[string]dockerLogger.Info
}

func NewMockLookup

func NewMockLookup() *MockLookup

func (*MockLookup) Lookup

func (m *MockLookup) Lookup(id string) (dockerLogger.Info, error)

Jump to

Keyboard shortcuts

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