commands

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Nov 19, 2022 License: Apache-2.0 Imports: 27 Imported by: 0

Documentation

Overview

Copyright © 2022 Symbiosis

Copyright © 2022 Symbiosis

Index

Constants

View Source
const (
	VERSION = "v0.0.2"
)

Variables

View Source
var (
	EnableBetaCommands bool
)
View Source
var InfoCommands = []string{"node-types", "regions", "roles"}
View Source
var RootCmd = &cobra.Command{
	Use:          "sym <command> <subcommand>",
	Short:        "Easily manage your Symbiosis resources using this CLI application.",
	Long:         ``,
	SilenceUsage: true,
	PersistentPreRunE: func(command *cobra.Command, args []string) error {

		err := symcommand.Initialise(commands, command)

		if err != nil {
			return err
		}

		return nil
	},
}

RootCmd represents the base command when called without any subcommands

Functions

func ConfirmPreRunE

func ConfirmPreRunE(prompt string) error

func Execute

func Execute()

Execute adds all child commands to the root command and sets flags appropriately. This is called by main.main(). It only needs to happen once to the rootCmd.

Types

type ApiKeysCommand

type ApiKeysCommand struct {
	Client      *symbiosis.Client
	CommandOpts *symcommand.CommandOpts
}

func (*ApiKeysCommand) Command

func (n *ApiKeysCommand) Command() *cobra.Command

func (*ApiKeysCommand) Execute

func (n *ApiKeysCommand) Execute(command *cobra.Command, args []string)

func (*ApiKeysCommand) Init

func (c *ApiKeysCommand) Init(client *symbiosis.Client, opts *symcommand.CommandOpts)

type ApplyCommand

type ApplyCommand struct {
	Client      *symbiosis.Client
	CommandOpts *symcommand.CommandOpts
}

func (*ApplyCommand) Command

func (c *ApplyCommand) Command() *cobra.Command

func (*ApplyCommand) Execute

func (c *ApplyCommand) Execute(command *cobra.Command, args []string) error

func (*ApplyCommand) Init

func (c *ApplyCommand) Init(client *symbiosis.Client, opts *symcommand.CommandOpts)

type ClusterCommand

type ClusterCommand struct {
	Client      *symbiosis.Client
	CommandOpts *symcommand.CommandOpts
}

func (*ClusterCommand) Command

func (c *ClusterCommand) Command() *cobra.Command

func (*ClusterCommand) Init

func (c *ClusterCommand) Init(client *symbiosis.Client, opts *symcommand.CommandOpts)

type InfoCommand

type InfoCommand struct {
	Client      *symbiosis.Client
	CommandOpts *symcommand.CommandOpts
}

func (*InfoCommand) Command

func (c *InfoCommand) Command() *cobra.Command

func (*InfoCommand) Execute

func (c *InfoCommand) Execute(command *cobra.Command, args []string) error

func (*InfoCommand) Init

func (c *InfoCommand) Init(client *symbiosis.Client, opts *symcommand.CommandOpts)

type LoginCommand

type LoginCommand struct {
	Client      *symbiosis.Client
	CommandOpts *symcommand.CommandOpts
}

func (*LoginCommand) Command

func (c *LoginCommand) Command() *cobra.Command

func (*LoginCommand) Init

func (c *LoginCommand) Init(client *symbiosis.Client, opts *symcommand.CommandOpts)

type NodePoolCommand

type NodePoolCommand struct {
	Client      *symbiosis.Client
	CommandOpts *symcommand.CommandOpts
}

func (*NodePoolCommand) Command

func (n *NodePoolCommand) Command() *cobra.Command

func (*NodePoolCommand) Execute

func (n *NodePoolCommand) Execute(command *cobra.Command, args []string)

func (*NodePoolCommand) Init

func (c *NodePoolCommand) Init(client *symbiosis.Client, opts *symcommand.CommandOpts)

type RunCommand

type RunCommand struct {
	Client      *symbiosis.Client
	CommandOpts *symcommand.CommandOpts
}

func (*RunCommand) Command

func (c *RunCommand) Command() *cobra.Command

func (*RunCommand) Execute

func (c *RunCommand) Execute(command *cobra.Command, args []string) error

func (*RunCommand) Init

func (c *RunCommand) Init(client *symbiosis.Client, opts *symcommand.CommandOpts)

type RunState

type RunState struct {
	ID      string `json:"id"`
	Cluster string `json:"cluster"`
	State   string `json:"state"`
}

TODO: WRITE STATE

type VersionCommand

type VersionCommand struct {
	Client      *symbiosis.Client
	CommandOpts *symcommand.CommandOpts
}

func (*VersionCommand) Command

func (n *VersionCommand) Command() *cobra.Command

func (*VersionCommand) Execute

func (n *VersionCommand) Execute(command *cobra.Command, args []string)

func (*VersionCommand) Init

func (c *VersionCommand) Init(client *symbiosis.Client, opts *symcommand.CommandOpts)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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