aws

package
v0.37.0 Latest Latest
Warning

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

Go to latest
Published: Jan 19, 2018 License: MIT Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateAwsConfig added in v0.28.1

func CreateAwsConfig(options Options) *aws.Config

CreateAwsConfig returns an aws.Config for the given profile and region

func CreateRepository added in v0.28.1

func CreateRepository(ecrClient *ecr.ECR, repositoryName string) (string, error)

CreateRepository creates a repository with the given name if one does not exist returns the repositoryURI

func DeleteSecrets

func DeleteSecrets(existingSecrets types.Secrets, secretKeys []string, options Options) error

DeleteSecrets deletes a list of secrets provided their keys. Ignores them if they don't exist

func GetECRCredentials added in v0.28.1

func GetECRCredentials(ecrClient *ecr.ECR) (string, error)

GetECRCredentials returns base64 encoded ECR auth object

func InitAccount

func InitAccount(options Options) error

InitAccount prepares a blank AWS account to be used with Terraform

func MergeAndWriteSecrets

func MergeAndWriteSecrets(existingSecrets, newSecrets types.Secrets, options Options) error

MergeAndWriteSecrets merges two secret maps and writes them to s3 Overwrites existingSecrets's values if the are conflicting keys

func ReadSecrets

func ReadSecrets(options Options) (types.Secrets, error)

ReadSecrets reads secret key value pair from remote store It creates an empty secrets store if necessary

Types

type Options added in v0.36.1

type Options struct {
	BucketName         string
	Profile            string
	Region             string
	TerraformLockTable string
}

Options is the structure for options to most functions

type RepositoryHelper added in v0.28.1

type RepositoryHelper struct {
	EcrAuth        string
	EcrClient      *ecr.ECR
	ImageName      string
	RepositoryName string
	RepositoryURI  string
	ImageVersion   string
}

RepositoryHelper is used for help pushing an image to ECR

func (*RepositoryHelper) GetTaggedImageName added in v0.28.1

func (r *RepositoryHelper) GetTaggedImageName() string

GetTaggedImageName returns the image name on ECR

func (*RepositoryHelper) NeedsPush added in v0.28.1

func (r *RepositoryHelper) NeedsPush() (bool, error)

NeedsPush returns whether or not the image needs to be pushed

func (*RepositoryHelper) Push added in v0.28.1

func (r *RepositoryHelper) Push(writer io.Writer) error

Push pushes the image to ECR

Jump to

Keyboard shortcuts

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