Documentation
¶
Index ¶
- Variables
- type Container
- type InfoClient
- func (c *InfoClient) GetAppContainer(containerId string, useCache bool) (*Container, error)
- func (c *InfoClient) GetClient() *docker.Client
- func (c *InfoClient) GetContainer(containerId string, useCache bool, requiredEnvs []string) (*Container, error)
- func (c *InfoClient) ListContainers() ([]docker.APIContainers, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrTsuruVariablesNotFound = errors.New("could not find wanted envs")
)
Functions ¶
This section is empty.
Types ¶
type Container ¶
type Container struct { docker.Container TsuruApp bool AppName string ProcessName string ShortHostname string Tags []string RawExtra *json.RawMessage // contains filtered or unexported fields }
func (*Container) GetLabelAny ¶
GetLabelAny returns the first label value that exists with given names
func (*Container) IsIsolated ¶
type InfoClient ¶
type InfoClient struct {
// contains filtered or unexported fields
}
func NewClient ¶
func NewClient(endpoint string) (*InfoClient, error)
func (*InfoClient) GetAppContainer ¶
func (c *InfoClient) GetAppContainer(containerId string, useCache bool) (*Container, error)
GetAppContainer returns the container with id containerId if that container is an tsuru application. It may use a cache to prevent calling the docker api.
func (*InfoClient) GetClient ¶
func (c *InfoClient) GetClient() *docker.Client
func (*InfoClient) GetContainer ¶
func (c *InfoClient) GetContainer(containerId string, useCache bool, requiredEnvs []string) (*Container, error)
GetContainer returns the container with the provided id if the container has the required environment variable. It may use a cache to prevent calling the docker api.
func (*InfoClient) ListContainers ¶
func (c *InfoClient) ListContainers() ([]docker.APIContainers, error)
Click to show internal directories.
Click to hide internal directories.