cfn

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Mar 23, 2020 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const StackNotFound = CloudFormationError("Stack not found")

StackNotFound indicates a stack doesn't exist that matches the search

Variables

This section is empty.

Functions

func New

func New(sess *session.Session) project.Provider

New returns a CloudFormation Provider

Types

type CloudFormationError

type CloudFormationError string

CloudFormationError is a simple error type

func (CloudFormationError) Error

func (e CloudFormationError) Error() string

type Provider

type Provider struct {
	// contains filtered or unexported fields
}

Provider implements CloudFormation support for Zim

func (*Provider) DescribeStack

func (p *Provider) DescribeStack(stackName string) (*cf.Stack, error)

DescribeStack returns information about the named CloudFormation Stack

func (*Provider) Init

func (p *Provider) Init(opts map[string]interface{}) error

Init sets up the AWS session for this Provider

func (*Provider) ListStacks

func (p *Provider) ListStacks() ([]*cf.StackSummary, error)

ListStacks finds all CloudFormation stacks

func (*Provider) Match

func (p *Provider) Match(pattern string) (project.Resources, error)

Match Stacks by name

func (*Provider) Name

func (p *Provider) Name() string

Name identifies the type name of this Provider

func (*Provider) New

func (p *Provider) New(path string) project.Resource

New returns a Stack Resource

type Stack

type Stack struct {
	// contains filtered or unexported fields
}

Stack represents a CloudFormation stack as a Zim Resource

func NewStack

func NewStack(provider *Provider, path string) *Stack

NewStack returns a Stack given the path

func (*Stack) AsFile

func (s *Stack) AsFile() (string, error)

AsFile returns the path to the file

func (*Stack) Cacheable

func (s *Stack) Cacheable() bool

Cacheable is false for Stacks since they can be uploaded to a cache

func (*Stack) Exists

func (s *Stack) Exists() (bool, error)

Exists indicates whether the Stack currently exists

func (*Stack) Hash

func (s *Stack) Hash() (string, error)

Hash of Stack contents

func (*Stack) LastModified

func (s *Stack) LastModified() (time.Time, error)

LastModified returns the time when this Stack was last updated

func (*Stack) Name

func (s *Stack) Name() string

Name of the Resource

func (*Stack) OnFilesystem

func (s *Stack) OnFilesystem() bool

OnFilesystem is false for files

func (*Stack) Path

func (s *Stack) Path() string

Path returns the absolute path to the Stack

type StackState

type StackState struct {
	ID            string    `json:"id"`
	Changeset     string    `json:"changeset"`
	LastUpdatedAt time.Time `json:"last_updated_at"`
}

StackState is the basis for determining a hash of the current Stack state.

Jump to

Keyboard shortcuts

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