stack

package
v0.0.26-beta2 Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2018 License: MIT Imports: 18 Imported by: 2

Documentation

Index

Constants

View Source
const (
	LambdaSpotFunctionFilename = "lambda_spot_function.py"
	LambdaSpotZipFilename      = "lambda_spot.zip"
	ShellScriptFilename        = "build.sh"
)

Variables

This section is empty.

Functions

func AWSApply

func AWSApply(config StackConfig) error

func AWSDestroy

func AWSDestroy(config StackConfig) error

Types

type StackConfig

type StackConfig struct {
	Name            string
	Region          string
	Device          string
	AMI             string
	SpotPrice       string
	SSHKey          string
	PreventShutdown bool
	Version         string
	Schedule        string
	Force           bool
}

type TempDir

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

func NewTempDir

func NewTempDir(name string) (*TempDir, error)

func (*TempDir) Cleanup

func (tempDir *TempDir) Cleanup() error

func (*TempDir) Path

func (tempDir *TempDir) Path(filename string) string

func (*TempDir) Save

func (tempDir *TempDir) Save(filename string, contents []byte) (string, error)

type TerraformClient

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

func NewTerraformClient

func NewTerraformClient(config *TerraformConfig, stdout, stderr io.Writer) (*TerraformClient, error)

func (*TerraformClient) Apply

func (client *TerraformClient) Apply() error

func (*TerraformClient) Cleanup

func (client *TerraformClient) Cleanup() error

func (*TerraformClient) Destroy

func (client *TerraformClient) Destroy() error

type TerraformConfig

type TerraformConfig struct {
	Name                    string
	Region                  string
	Device                  string
	TempDir                 *TempDir
	ShellScriptFile         string
	ShellScriptBytes        []byte
	LambdaSpotZipFile       string
	LambdaSpotFunctionBytes []byte
	PreventShutdown         bool
	Schedule                string
}

Jump to

Keyboard shortcuts

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