store

package
v0.0.0-...-8c0406d Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2018 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 SSMStore

type SSMStore struct {
	ServiceID  string
	Parameters []*ssm.Parameter
	SSM        ssmiface.SSMAPI
}

SSMStore contains the parameters, secrets, etc. stored in SSM

func New

func New(serviceID string) *SSMStore

New returns a new wrapper for the Lambda functionality

func (*SSMStore) GetEnv

func (s *SSMStore) GetEnv() (map[string]string, error)

GetEnv returns an environment of parameter name and value

func (*SSMStore) GetParameters

func (s *SSMStore) GetParameters() ([]*ssm.Parameter, error)

GetParameters fetches the SSM parameters for the configured ProjectID and also returns the parameters

func (*SSMStore) SetEnv

func (s *SSMStore) SetEnv() error

SetEnv is setting the available env variables to os

func (*SSMStore) TestEnv

func (s *SSMStore) TestEnv(parameters []string) (bool, error)

TestEnv is testing for the existence of required parameters

type Store

type Store interface {
	GetParameters() ([]*ssm.Parameter, error)
	GetEnv() (map[string]string, error)
	SetEnv() error
}

Store is the interface to a SSM Store

Jump to

Keyboard shortcuts

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