Documentation
¶
Index ¶
- type Cmd
- func (c *Cmd) AfterCommands(cCtx *cli.Context) error
- func (c *Cmd) BeforeCommands(cCtx *cli.Context) error
- func (c *Cmd) Favorites(cCtx *cli.Context) error
- func (c *Cmd) FedConsole(cCtx *cli.Context) error
- func (c *Cmd) FlushCache(cCtx *cli.Context) error
- func (c *Cmd) GenStaks(cCtx *cli.Context) error
- func (c *Cmd) ListFavorites(cCtx *cli.Context) error
- func (c *Cmd) PushFavorites(cCtx *cli.Context) error
- func (c *Cmd) RunCommand(cCtx *cli.Context) error
- func (c *Cmd) ValidateCmdConsole(cCtx *cli.Context) error
- func (c *Cmd) ValidateCmdRun(cCtx *cli.Context) error
- func (c *Cmd) ValidateCmdStak(cCtx *cli.Context) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Cmd ¶
type Cmd struct {
// contains filtered or unexported fields
}
Cmd is the main command object for the Kion CLI. It makes the configuration and cache available to all command actions.
func NewCommands ¶
func NewCommands(cfg *structs.Configuration) *Cmd
NewCommands stands up a new instance of commands with the provided configuration.
func (*Cmd) AfterCommands ¶
AfterCommands run after any subcommands are executed.
func (*Cmd) BeforeCommands ¶
BeforeCommands run after the context is ready but before any subcommands are executed. Currently used to test feature compatibility with targeted Kion.
func (*Cmd) Favorites ¶
Favorites generates short term access keys or launches the web console from stored favorites. If a favorite is found that matches the passed argument it is used, otherwise the user is walked through a wizard to make a selection.
func (*Cmd) FedConsole ¶
FedConsole opens the CSP console for the selected account and cloud access role in the user's default browser.
func (*Cmd) FlushCache ¶
FlushCache clears the Kion CLI cache.
func (*Cmd) GenStaks ¶
GenStaks generates short term access keys by walking users through an interactive prompt. Short term access keys are either printed to stdout or a sub-shell is created with them set in the environment.
func (*Cmd) ListFavorites ¶
ListFavorites prints out the users stored favorites. Extra information is provided if the verbose flag is set.
func (*Cmd) PushFavorites ¶
PushFavorites pushes the local favorites to a target instance of Kion.
func (*Cmd) RunCommand ¶
RunCommand generates creds for an AWS account then executes the user provided command with said credentials set.
func (*Cmd) ValidateCmdConsole ¶
validateCmdConsole validates the flags passed to the console command.
func (*Cmd) ValidateCmdRun ¶
validateCmdRun validates the flags passed to the run command.