object

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: May 29, 2017 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Container

type Container struct {
	Image       string
	Environment []EnvVariable
	Ports       []Port
	Mounts      []Mount
}

type EmptyDirVolume added in v0.2.0

type EmptyDirVolume struct {
	Name string
}

type EnvVariable

type EnvVariable struct {
	Key   string
	Value string
}

type Labels added in v0.2.0

type Labels map[string]string

type Mount added in v0.2.0

type Mount struct {
	VolumeRef     string
	MountPath     string
	VolumeSubPath string
	ReadOnly      bool
}

type OpenCompose

type OpenCompose struct {
	Version  string
	Services []Service
	Volumes  []Volume
}

func (*OpenCompose) Validate

func (o *OpenCompose) Validate() error

Does high level (mostly semantic) validation of OpenCompose (e.g. it checks internal object references)

func (*OpenCompose) VolumeExists added in v0.2.0

func (o *OpenCompose) VolumeExists(name string) bool

Given name of root level 'volume' this function searches if opencompose receiver has that 'volume'.

type Port

type Port struct {
	Port PortMapping
	Type PortType
	Host *string
	Path string
}

type PortMapping

type PortMapping struct {
	ContainerPort int
	ServicePort   int
}

type PortType

type PortType int
const (
	PortType_Internal PortType = iota
	PortType_External
)

type Service

type Service struct {
	Name            string
	Containers      []Container
	Replicas        *int32
	EmptyDirVolumes []EmptyDirVolume
	Labels          Labels
}

func (*Service) EmptyDirVolumeExists added in v0.2.0

func (s *Service) EmptyDirVolumeExists(name string) bool

Given the name of 'emptyDirVolume' this function searches if service receiver has that 'emptyDirVolume'

type Volume

type Volume struct {
	Name         string
	Size         string
	AccessMode   string
	StorageClass *string
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
JackTT - Gopher 🇻🇳