spec

package
v0.16.0 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2018 License: Apache-2.0 Imports: 3 Imported by: 24

Documentation

Index

Constants

View Source
const (
	DefaultPort    = 5000
	SlugAnnotation = "teresa.io/slug"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Container added in v0.16.0

type Container struct {
	Name            string
	Namespace       string
	Image           string
	ContainerLimits *ContainerLimits
	Env             map[string]string
	VolumeMounts    []*VolumeMounts
	Args            []string
}

type ContainerLimits

type ContainerLimits struct {
	CPU    string
	Memory string
}

type CronArgs added in v0.16.0

type CronArgs struct {
	Schedule string `yaml:"schedule",omitempty"`
}

type CronJob added in v0.16.0

type CronJob struct {
	Deploy
	Schedule                   string
	SuccessfulJobsHistoryLimit int32
	FailedJobsHistoryLimit     int32
}

func NewCronJob added in v0.16.0

func NewCronJob(description, slugURL, schedule string, imgs *SlugImages, a *app.App, fs storage.Storage, args ...string) *CronJob

type Deploy

type Deploy struct {
	Pod
	TeresaYaml
	RevisionHistoryLimit int
	Description          string
	SlugURL              string
}

func NewDeploy

func NewDeploy(imgs *SlugImages, description, slugURL string, rhl int, a *app.App, tYaml *TeresaYaml, fs storage.Storage) *Deploy

type HealthCheck

type HealthCheck struct {
	Liveness  *HealthCheckProbe
	Readiness *HealthCheckProbe
}

type HealthCheckProbe

type HealthCheckProbe struct {
	FailureThreshold    int32  `yaml:"failureThreshold"`
	InitialDelaySeconds int32  `yaml:"initialDelaySeconds"`
	PeriodSeconds       int32  `yaml:"periodSeconds"`
	SuccessThreshold    int32  `yaml:"successThreshold"`
	TimeoutSeconds      int32  `yaml:"timeoutSeconds"`
	Path                string `yaml:"path"`
}

type Lifecycle

type Lifecycle struct {
	PreStop *PreStop `yaml:"preStop,omitempty"`
}

type Pod

type Pod struct {
	Container
	Volumes        []*Volume
	InitContainers []*Container
}

func NewBuilder

func NewBuilder(name, tarBallLocation, buildDest, image string, a *app.App, fs storage.Storage, cl *ContainerLimits) *Pod

func NewPod

func NewPod(name, image string, a *app.App, envVars map[string]string, fs storage.Storage) *Pod

func NewRunner

func NewRunner(name, slugURL string, imgs *SlugImages, a *app.App, fs storage.Storage, cl *ContainerLimits, command ...string) *Pod

type PreStop

type PreStop struct {
	DrainTimeoutSeconds int `yaml:"drainTimeoutSeconds,omitempty"`
}

type RollingUpdate

type RollingUpdate struct {
	MaxSurge       string `yaml:"maxSurge,omitempty"`
	MaxUnavailable string `yaml:"maxUnavailable,omitempty"`
}

type SlugImages added in v0.16.0

type SlugImages struct {
	Runner string
	Store  string
}

type TeresaYaml

type TeresaYaml struct {
	HealthCheck   *HealthCheck   `yaml:"healthCheck,omitempty"`
	RollingUpdate *RollingUpdate `yaml:"rollingUpdate,omitempty"`
	Lifecycle     *Lifecycle     `yaml:"lifecycle,omitempty"`
	Cron          *CronArgs      `yaml:"cron,omitempty"`
}

type Volume added in v0.16.0

type Volume struct {
	Name       string
	SecretName string
	EmptyDir   bool
}

type VolumeMounts added in v0.16.0

type VolumeMounts struct {
	Name      string
	MountPath string
	ReadOnly  bool
}

Jump to

Keyboard shortcuts

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