bifrost

package
v1.0.1-beta Latest Latest
Warning

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

Go to latest
Published: Feb 8, 2019 License: Apache-2.0 Imports: 9 Imported by: 6

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Release

type Release struct {
	AwsAccountID *string `json:"aws_account_id,omitempty"`
	AwsRegion    *string `json:"aws_region,omitempty"`

	ReleaseSHA256 string `json:"-"` // Not Set By Client, Not Marshalled

	UUID      *string `json:"uuid,omitempty"`       // Generated By server
	ReleaseID *string `json:"release_id,omitempty"` // Generated Client

	ProjectName *string `json:"project_name,omitempty"`
	ConfigName  *string `json:"config_name,omitempty"`
	Bucket      *string `json:"bucket,omitempty"` // Bucket with Additional Data in it

	CreatedAt *time.Time `json:"created_at,omitempty"`

	Timeout *int `json:"timeout,omitempty"` // How long should we try and deploy in seconds

	Error   *ReleaseError `json:"error,omitempty"`
	Success *bool         `json:"success,omitempty"`
}

Release is the Data Structure passed between Client and Deployer

func (*Release) AppendLog

func (release *Release) AppendLog(s3c aws.S3API, log string) error

func (*Release) ErrorPrefix

func (r *Release) ErrorPrefix() string

func (*Release) ExecutionName

func (r *Release) ExecutionName() *string

ExecutionName returns

func (*Release) ExecutionPrefix

func (r *Release) ExecutionPrefix() string

ExecutionPrefix returns

func (*Release) GrabLock

func (r *Release) GrabLock(s3c aws.S3API) error

GrabLock retrieves the Lock returns LockExistsError, or LockExistsError

func (*Release) Halt

func (r *Release) Halt(s3c aws.S3API, message *string) error

Halt writes Halt flag to S3 to attempt to stop the release

func (*Release) HaltPath

func (r *Release) HaltPath() *string

func (*Release) IsHalt

func (r *Release) IsHalt(s3c aws.S3API) error

IsHalt will error with if halt flag found

func (*Release) LockPath

func (r *Release) LockPath() *string

func (*Release) LogPath

func (release *Release) LogPath() *string

func (*Release) ReleaseDir

func (r *Release) ReleaseDir() *string

func (*Release) ReleaseLock

func (r *Release) ReleaseLock(s3c aws.S3API) error

ReleaseLock deletes the Lock File for the release

func (*Release) ReleasePath

func (r *Release) ReleasePath() *string

func (*Release) RemoveHalt

func (r *Release) RemoveHalt(s3c aws.S3API)

RemoveHalt deletes the halt flat from S3

func (*Release) RootDir

func (r *Release) RootDir() *string

func (*Release) SetDefaults

func (r *Release) SetDefaults(region *string, account *string, bucket_prefix string)

SetDefaults is passed the region and account where the lambda is executed AND the default-bucket-prefix to calculate the default bucket name

func (*Release) TimedOut

func (r *Release) TimedOut() error

func (*Release) Validate

func (r *Release) Validate(s3c aws.S3API, cRelease interface{}) error

Validate checks 1. the attributes are assigned 2. the time frame of created at is valid 3. the uploaded release sha is correct (requires S3 and &Release{})

func (*Release) WriteLog

func (release *Release) WriteLog(s3c aws.S3API, log string) error

type ReleaseError

type ReleaseError struct {
	Error *string
	Cause *string
}

ReleaseError contains the error and cause for the state machine

Jump to

Keyboard shortcuts

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