commands

package
v6.1.2+incompatible Latest Latest
Warning

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

Go to latest
Published: Feb 16, 2018 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Credentials = `` /* 1683-byte string literal not displayed */

	LBUsage = `` /* 457-byte string literal not displayed */

	PlanCommandUsage = `` /* 314-byte string literal not displayed */

	UpCommandUsage = `` /* 276-byte string literal not displayed */

	DestroyCommandUsage = `` /* 178-byte string literal not displayed */

	CleanupLeftoversCommandUsage = `Cleans up orphaned IAAS resources

  --filter            Only delete resources with this string in their name`

	LBsCommandUsage = "Prints attached load balancer(s)"

	VersionCommandUsage = "Prints version"

	UsageCommandUsage = "Prints helpful message for the given command"

	EnvIdCommandUsage = "Prints environment ID"

	SSHKeyCommandUsage = "Prints SSH private key for the jumpbox."

	DirectorSSHKeyCommandUsage = "Prints SSH private key for the director."

	RotateCommandUsage = "Rotates SSH key for the jumpbox user."

	JumpboxAddressCommandUsage = "Prints BOSH jumpbox address"

	DirectorUsernameCommandUsage = "Prints BOSH director username"

	DirectorPasswordCommandUsage = "Prints BOSH director password"

	DirectorAddressCommandUsage = "Prints BOSH director address"

	DirectorCACertCommandUsage = "Prints BOSH director CA certificate"

	PrintEnvCommandUsage = "Prints required BOSH environment variables"

	LatestErrorCommandUsage = "Prints the output from the latest call to terraform"
)
View Source
const (
	EnvIDCommand            = "env-id"
	JumpboxAddressCommand   = "jumpbox-address"
	DirectorUsernameCommand = "director-username"
	DirectorPasswordCommand = "director-password"
	DirectorAddressCommand  = "director-address"
	DirectorCACertCommand   = "director-ca-cert"

	EnvIDPropertyName            = "environment id"
	JumpboxAddressPropertyName   = "jumpbox address"
	DirectorUsernamePropertyName = "director username"
	DirectorPasswordPropertyName = "director password"
	DirectorAddressPropertyName  = "director address"
	DirectorCACertPropertyName   = "director ca cert"
)
View Source
const (
	UsageHeader = `` /* 459-byte string literal not displayed */

	CommandUsage = `
[%s command options]
  %s`
)
View Source
const GlobalUsage = `` /* 1391-byte string literal not displayed */

Variables

This section is empty.

Functions

This section is empty.

Types

type AWSLBs

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

func NewAWSLBs

func NewAWSLBs(terraformManager terraformManager, logger logger) AWSLBs

func (AWSLBs) Execute

func (l AWSLBs) Execute(subcommandFlags []string, state storage.State) error

type AzureLBs

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

func NewAzureLBs

func NewAzureLBs(terraformManager terraformManager, logger logger) AzureLBs

func (AzureLBs) Execute

func (l AzureLBs) Execute(subcommandFlags []string, state storage.State) error

type CleanupLeftovers

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

func NewCleanupLeftovers

func NewCleanupLeftovers(deleter FilteredDeleter) CleanupLeftovers

func (CleanupLeftovers) CheckFastFails

func (l CleanupLeftovers) CheckFastFails(subcommandFlags []string, state storage.State) error

func (CleanupLeftovers) Execute

func (l CleanupLeftovers) Execute(subcommandFlags []string, state storage.State) error

func (CleanupLeftovers) Usage

func (l CleanupLeftovers) Usage() string

type Command

type Command interface {
	CheckFastFails(subcommandFlags []string, state storage.State) error
	Execute(subcommandFlags []string, state storage.State) error
	Usage() string
}

type Destroy

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

func NewDestroy

func NewDestroy(plan plan, logger logger, boshManager boshManager, stateStore stateStore,
	stateValidator stateValidator, terraformManager terraformManager,
	networkDeletionValidator NetworkDeletionValidator) Destroy

func (Destroy) CheckFastFails

func (d Destroy) CheckFastFails(subcommandFlags []string, state storage.State) error

func (Destroy) Execute

func (d Destroy) Execute(subcommandFlags []string, state storage.State) error

func (Destroy) Usage

func (Destroy) Usage() string

type FilteredDeleter

type FilteredDeleter interface {
	Delete(filter string) error
}

type GCPLBs

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

func NewGCPLBs

func NewGCPLBs(terraformManager terraformManager, logger logger) GCPLBs

func (GCPLBs) Execute

func (l GCPLBs) Execute(subcommandFlags []string, state storage.State) error

type GlobalFlags

type GlobalFlags struct {
	AWSAccessKeyID     string
	AWSSecretAccessKey string
	AWSRegion          string
	StateDir           string
}

type LBArgs

type LBArgs struct {
	LBType    string
	CertPath  string
	KeyPath   string
	ChainPath string
	Domain    string
}

type LBArgsHandler

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

func NewLBArgsHandler

func NewLBArgsHandler(certificateValidator certificateValidator) LBArgsHandler

func (LBArgsHandler) GetLBState

func (l LBArgsHandler) GetLBState(iaas string, args LBArgs) (storage.LB, error)

func (LBArgsHandler) Merge

func (l LBArgsHandler) Merge(new storage.LB, old storage.LB) storage.LB

type LBs

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

func NewLBs

func NewLBs(lbs LBsCmd, stateValidator stateValidator) LBs

func (LBs) CheckFastFails

func (l LBs) CheckFastFails(subcommandFlags []string, state storage.State) error

func (LBs) Execute

func (l LBs) Execute(subcommandFlags []string, state storage.State) error

func (LBs) Usage

func (LBs) Usage() string

type LBsCmd

type LBsCmd interface {
	Execute([]string, storage.State) error
}

type LatestError

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

func NewLatestError

func NewLatestError(logger logger, stateValidator stateValidator) LatestError

func (LatestError) CheckFastFails

func (l LatestError) CheckFastFails(subcommandFlags []string, state storage.State) error

func (LatestError) Execute

func (l LatestError) Execute(subcommandFlags []string, bblState storage.State) error

func (LatestError) Usage

func (LatestError) Usage() string

type NetworkDeletionValidator

type NetworkDeletionValidator interface {
	ValidateSafeToDelete(networkName string, envID string) error
}

type Plan

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

func NewPlan

func NewPlan(boshManager boshManager,
	cloudConfigManager cloudConfigManager,
	stateStore stateStore,
	envIDManager envIDManager,
	terraformManager terraformManager,
	lbArgsHandler lbArgsHandler,
	logger logger,
	bblVersion string,
) Plan

func (Plan) CheckFastFails

func (p Plan) CheckFastFails(args []string, state storage.State) error

func (Plan) Execute

func (p Plan) Execute(args []string, state storage.State) error

func (Plan) InitializePlan

func (p Plan) InitializePlan(config PlanConfig, state storage.State) (storage.State, error)

func (Plan) IsInitialized

func (p Plan) IsInitialized(state storage.State) bool

func (Plan) ParseArgs

func (p Plan) ParseArgs(args []string, state storage.State) (PlanConfig, error)

func (Plan) Usage

func (Plan) Usage() string

type PlanConfig

type PlanConfig struct {
	Name string
	LB   storage.LB
}

type PrintEnv

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

func NewPrintEnv

func NewPrintEnv(
	logger logger,
	stderrLogger logger,
	stateValidator stateValidator,
	allProxyGetter allProxyGetter,
	credhubGetter credhubGetter,
	terraformManager terraformManager,
	fs fs) PrintEnv

func (PrintEnv) CheckFastFails

func (p PrintEnv) CheckFastFails(subcommandFlags []string, state storage.State) error

func (PrintEnv) Execute

func (p PrintEnv) Execute(args []string, state storage.State) error

func (PrintEnv) Usage

func (PrintEnv) Usage() string

type Rotate

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

func NewRotate

func NewRotate(stateValidator stateValidator, sshKeyDeleter sshKeyDeleter, up up) Rotate

func (Rotate) CheckFastFails

func (r Rotate) CheckFastFails(subcommandFlags []string, state storage.State) error

func (Rotate) Execute

func (r Rotate) Execute(args []string, state storage.State) error

func (Rotate) Usage

func (Rotate) Usage() string

type SSHKey

type SSHKey struct {
	Director bool
	// contains filtered or unexported fields
}

func NewDirectorSSHKey

func NewDirectorSSHKey(logger logger, stateValidator stateValidator, sshKeyGetter sshKeyGetter) SSHKey

func NewSSHKey

func NewSSHKey(logger logger, stateValidator stateValidator, sshKeyGetter sshKeyGetter) SSHKey

func (SSHKey) CheckFastFails

func (s SSHKey) CheckFastFails(subcommandFlags []string, state storage.State) error

func (SSHKey) Execute

func (s SSHKey) Execute(subcommandFlags []string, state storage.State) error

func (SSHKey) Usage

func (s SSHKey) Usage() string

type StateQuery

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

func NewStateQuery

func NewStateQuery(logger logger, stateValidator stateValidator, terraformManager terraformManager, propertyName string) StateQuery

func (StateQuery) CheckFastFails

func (s StateQuery) CheckFastFails(subcommandFlags []string, state storage.State) error

func (StateQuery) Execute

func (s StateQuery) Execute(subcommandFlags []string, state storage.State) error

func (StateQuery) Usage

func (s StateQuery) Usage() string

type Up

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

func NewUp

func NewUp(
	plan plan,
	boshManager boshManager,
	cloudConfigManager cloudConfigManager,
	stateStore stateStore,
	terraformManager terraformManager,
) Up

func (Up) CheckFastFails

func (u Up) CheckFastFails(args []string, state storage.State) error

func (Up) Execute

func (u Up) Execute(args []string, state storage.State) error

func (Up) ParseArgs

func (u Up) ParseArgs(args []string, state storage.State) (PlanConfig, error)

func (Up) Usage

func (Up) Usage() string

type Usage

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

func NewUsage

func NewUsage(logger logger) Usage

func (Usage) CheckFastFails

func (u Usage) CheckFastFails(subcommandFlags []string, state storage.State) error

func (Usage) Execute

func (u Usage) Execute(subcommandFlags []string, state storage.State) error

func (Usage) Print

func (u Usage) Print()

func (Usage) PrintCommandUsage

func (u Usage) PrintCommandUsage(command, message string)

func (Usage) Usage

func (Usage) Usage() string

type Version

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

func NewVersion

func NewVersion(version string, logger logger) Version

func (Version) CheckFastFails

func (v Version) CheckFastFails(subcommandFlags []string, state storage.State) error

func (Version) Execute

func (v Version) Execute(subcommandFlags []string, state storage.State) error

func (Version) Usage

func (Version) Usage() string

Jump to

Keyboard shortcuts

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