parameterstore

package
v1.4.9 Latest Latest
Warning

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

Go to latest
Published: Feb 14, 2024 License: MIT Imports: 10 Imported by: 2

Documentation

Index

Constants

View Source
const (
	Delimiter            = "/"
	DefaultParameterType = "SecureString"
)

Delimiter is the parameter path separator character

Variables

This section is empty.

Functions

This section is empty.

Types

type ListResult

type ListResult struct {
	Result []string
	Error  error
}

ListResult contains the results and error message from a call to List()

type ParameterPath added in v1.4.1

type ParameterPath struct {
	Name   string
	Region string
}

ParameterPath abstracts a parameter to include some metadata

type ParameterStore

type ParameterStore struct {
	Cwd       string                     // The current working directory in the hierarchy
	Decrypt   bool                       // Decrypt values retrieved from Get
	Type      string                     // Default parameter type (String, SecureString, StringList)
	Key       string                     // The KMS key to use for SecureString parameters
	Region    string                     // AWS region on which to operate
	Overwrite bool                       // Whether or not to overwrite parameters
	Profile   string                     // Profile to use from .aws/[config|credentials]
	Clients   map[string]ssmiface.SSMAPI // per-region SSM clients
}

ParameterStore represents the current state and preferences of the shell

func (*ParameterStore) Copy

func (ps *ParameterStore) Copy(src, dst ParameterPath, recurse bool) error

Copy duplicates a parameter from src to dst

func (*ParameterStore) Get

func (ps *ParameterStore) Get(params []string, region string) (r []ssm.Parameter, err error)

Get retrieves one or more parameters

func (*ParameterStore) GetHistory

func (ps *ParameterStore) GetHistory(param ParameterPath) (r []ssm.ParameterHistory, err error)

GetHistory returns the parameter history

func (*ParameterStore) InitClient added in v1.4.1

func (ps *ParameterStore) InitClient(region string)

InitClient initializes an SSM client in a given region

func (*ParameterStore) List

func (ps *ParameterStore) List(ppath ParameterPath, recurse bool, lr chan ListResult, quit chan bool)

List displays the parameters in a given path Behavior is vaguely similar to UNIX ls

func (*ParameterStore) Move

func (ps *ParameterStore) Move(src, dst ParameterPath) error

Move moves a parameter or path to another location

func (*ParameterStore) NewParameterStore

func (ps *ParameterStore) NewParameterStore(checkCredentials bool) error

NewParameterStore initializes a ParameterStore with default values

func (*ParameterStore) Put

func (ps *ParameterStore) Put(param *ssm.PutParameterInput, region string) (resp *ssm.PutParameterOutput, err error)

Put creates or updates a parameter

func (*ParameterStore) Remove

func (ps *ParameterStore) Remove(params []ParameterPath, recurse bool) (err error)

Remove removes one or more parameters

func (*ParameterStore) SetCwd

func (ps *ParameterStore) SetCwd(path ParameterPath) error

SetCwd sets the current working dir within the parameter store

func (*ParameterStore) SetDefaults added in v1.4.1

func (ps *ParameterStore) SetDefaults(cfg config.Config)

SetConfig sets the shels configuration state

Jump to

Keyboard shortcuts

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