Documentation
¶
Index ¶
- func GetCloudformationClient(profile string, region string) (string, *cloudformation.CloudFormation)
- func GetStackName(manifestFile *manifest.Manifest, fileName, environment, stackNameFlag string) string
- func ResolveParameters(environment string, cliParams map[string]string, cfYaml YamlCloudformation, ...) []*awsCF.Parameter
- func ResolveParametersS3(c *cli.Context, manifestFile *manifest.Manifest) []*awsCF.Parameter
- type GenerateParams
- type Parameter
- type StackDeleter
- type StackEventer
- type StackUpserter
- type Wrapper
- func (wr *Wrapper) CreateChangeSet(in *awsCF.CreateChangeSetInput) (*awsCF.CreateChangeSetOutput, error)
- func (wr *Wrapper) DeleteChangeSet(in *awsCF.DeleteChangeSetInput) (*awsCF.DeleteChangeSetOutput, error)
- func (wr *Wrapper) DeleteStack(in *awsCF.DeleteStackInput) (*awsCF.DeleteStackOutput, error)
- func (wr *Wrapper) DescribeChangeSet(in *awsCF.DescribeChangeSetInput) (*awsCF.DescribeChangeSetOutput, error)
- func (wr *Wrapper) DescribeStackEvents(input *awsCF.DescribeStackEventsInput) (*awsCF.DescribeStackEventsOutput, error)
- func (wr *Wrapper) DescribeStackEventsPages(input *awsCF.DescribeStackEventsInput, ...) error
- func (wr *Wrapper) DescribeStacks(in *awsCF.DescribeStacksInput) (*awsCF.DescribeStacksOutput, error)
- func (wr *Wrapper) ExecuteChangeSet(in *awsCF.ExecuteChangeSetInput) (*awsCF.ExecuteChangeSetOutput, error)
- func (wr *Wrapper) Open(profile, region string) string
- func (wr *Wrapper) WaitUntilChangeSetCreateComplete(in *awsCF.DescribeChangeSetInput) error
- type YamlCloudformation
- type YamlConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetCloudformationClient ¶ added in v0.3.7
func GetCloudformationClient(profile string, region string) (string, *cloudformation.CloudFormation)
GetCloudformationClient from the standard credential chain
func GetStackName ¶
func GetStackName(manifestFile *manifest.Manifest, fileName, environment, stackNameFlag string) string
GetStackName cleaned to fix AWS requirements
func ResolveParameters ¶
func ResolveParameters( environment string, cliParams map[string]string, cfYaml YamlCloudformation, manifestFile *manifest.Manifest, ) []*awsCF.Parameter
ResolveParameters for the template
Types ¶
type GenerateParams ¶
type GenerateParams struct {
ObjectStore core.ObjectStore
Filename string
Directory string
WriteParams bool
EnvFile string
Env string
GenerateDefaultOutputs bool
ParamMap map[string]string
Plugins []*plugins.PluginLoaded
}
GenerateParams are required to generate a cloudformation yaml template
type Parameter ¶ added in v0.3.4
type Parameter struct {
ParameterKey string
ParameterValue string
ResolvedValue string `json:"ResolvedValue,omitempty"`
UsePreviousValue bool `json:"UsePreviousValue,omitempty"`
}
CloudFormation Parameter data type: https://docs.aws.amazon.com/AWSCloudFormation/latest/APIReference/API_Parameter.html
type StackDeleter ¶ added in v0.3.7
type StackDeleter interface {
Open(string, string) string
DeleteStack(*awsCF.DeleteStackInput) (*awsCF.DeleteStackOutput, error)
DescribeStackEvents(*awsCF.DescribeStackEventsInput) (*awsCF.DescribeStackEventsOutput, error)
DescribeStackEventsPages(*awsCF.DescribeStackEventsInput, func(*awsCF.DescribeStackEventsOutput, bool) bool) error
DescribeStacks(*awsCF.DescribeStacksInput) (*awsCF.DescribeStacksOutput, error)
}
type StackEventer ¶ added in v0.3.7
type StackEventer interface {
Open(string, string) string
DescribeStackEvents(*awsCF.DescribeStackEventsInput) (*awsCF.DescribeStackEventsOutput, error)
DescribeStackEventsPages(*awsCF.DescribeStackEventsInput, func(*awsCF.DescribeStackEventsOutput, bool) bool) error
}
Subset of AWS API calls required by the events task, as a mockable interface.
type StackUpserter ¶ added in v0.3.7
type StackUpserter interface {
Open(string, string) string
CreateChangeSet(*awsCF.CreateChangeSetInput) (*awsCF.CreateChangeSetOutput, error)
DeleteChangeSet(*awsCF.DeleteChangeSetInput) (*awsCF.DeleteChangeSetOutput, error)
DeleteStack(*awsCF.DeleteStackInput) (*awsCF.DeleteStackOutput, error)
DescribeChangeSet(*awsCF.DescribeChangeSetInput) (*awsCF.DescribeChangeSetOutput, error)
DescribeStackEvents(*awsCF.DescribeStackEventsInput) (*awsCF.DescribeStackEventsOutput, error)
DescribeStackEventsPages(*awsCF.DescribeStackEventsInput, func(*awsCF.DescribeStackEventsOutput, bool) bool) error
DescribeStacks(*awsCF.DescribeStacksInput) (*awsCF.DescribeStacksOutput, error)
ExecuteChangeSet(*awsCF.ExecuteChangeSetInput) (*awsCF.ExecuteChangeSetOutput, error)
WaitUntilChangeSetCreateComplete(*awsCF.DescribeChangeSetInput) error
}
Subset of AWS API calls required by the upsert task, as a mockable interface.
type Wrapper ¶ added in v0.3.7
type Wrapper struct {
// contains filtered or unexported fields
}
func NewWrapper ¶ added in v0.3.7
func NewWrapper(client *awsCF.CloudFormation) *Wrapper
Placeholder helper so that tasks still using awsCF.CloudFormation directly can wrap it to use helpers that have been updated to use interfaces.
func (*Wrapper) CreateChangeSet ¶ added in v0.3.7
func (wr *Wrapper) CreateChangeSet(in *awsCF.CreateChangeSetInput) (*awsCF.CreateChangeSetOutput, error)
func (*Wrapper) DeleteChangeSet ¶ added in v0.3.7
func (wr *Wrapper) DeleteChangeSet(in *awsCF.DeleteChangeSetInput) (*awsCF.DeleteChangeSetOutput, error)
func (*Wrapper) DeleteStack ¶ added in v0.3.7
func (wr *Wrapper) DeleteStack(in *awsCF.DeleteStackInput) (*awsCF.DeleteStackOutput, error)
func (*Wrapper) DescribeChangeSet ¶ added in v0.3.7
func (wr *Wrapper) DescribeChangeSet(in *awsCF.DescribeChangeSetInput) (*awsCF.DescribeChangeSetOutput, error)
func (*Wrapper) DescribeStackEvents ¶ added in v0.3.7
func (wr *Wrapper) DescribeStackEvents(input *awsCF.DescribeStackEventsInput) (*awsCF.DescribeStackEventsOutput, error)
func (*Wrapper) DescribeStackEventsPages ¶ added in v0.3.7
func (wr *Wrapper) DescribeStackEventsPages(input *awsCF.DescribeStackEventsInput, fn func(*awsCF.DescribeStackEventsOutput, bool) bool) error
func (*Wrapper) DescribeStacks ¶ added in v0.3.7
func (wr *Wrapper) DescribeStacks(in *awsCF.DescribeStacksInput) (*awsCF.DescribeStacksOutput, error)
func (*Wrapper) ExecuteChangeSet ¶ added in v0.3.7
func (wr *Wrapper) ExecuteChangeSet(in *awsCF.ExecuteChangeSetInput) (*awsCF.ExecuteChangeSetOutput, error)
func (*Wrapper) WaitUntilChangeSetCreateComplete ¶ added in v0.3.7
func (wr *Wrapper) WaitUntilChangeSetCreateComplete(in *awsCF.DescribeChangeSetInput) error
type YamlCloudformation ¶
type YamlCloudformation struct {
AWSTemplateFormatVersion string `yaml:"AWSTemplateFormatVersion,omitempty"`
Description string `yaml:"Description,omitempty"`
Metadata types.TemplateObject `yaml:"Metadata,omitempty"`
Parameters types.TemplateObject `yaml:"Parameters,omitempty"`
Mappings types.TemplateObject `yaml:"Mappings,omitempty"`
Conditions types.TemplateObject `yaml:"Conditions,omitempty"`
Transform types.TemplateObject `yaml:"Transform,omitempty"`
Resources types.TemplateObject `yaml:"Resources"`
Outputs types.TemplateObject `yaml:"Outputs,omitempty"`
}
YamlCloudformation -
func GenerateYamlTemplate ¶ added in v0.3.0
func GenerateYamlTemplate(params GenerateParams) (compiledTemplate YamlCloudformation, err error)
GenerateYamlTemplate - generate a cloudformation template
type YamlConfig ¶
type YamlConfig struct {
AWSTemplateFormatVersion string `yaml:"AWSTemplateFormatVersion,omitempty"`
Description string `yaml:"Description,omitempty"`
Metadata types.TemplateObject `yaml:"Metadata,omitempty"`
Parameters types.TemplateObject `yaml:"Parameters,omitempty"`
Mappings types.TemplateObject `yaml:"Mappings,omitempty"`
Conditions types.TemplateObject `yaml:"Conditions,omitempty"`
Transform types.TemplateObject `yaml:"Transform,omitempty"`
Resources map[string]types.CfResource `yaml:"Resources"`
Outputs types.TemplateObject `yaml:"Outputs,omitempty"`
}
YamlConfig -