cmd

package
v3.4.5 Latest Latest
Warning

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

Go to latest
Published: Apr 17, 2024 License: MPL-2.0 Imports: 54 Imported by: 3

Documentation

Index

Constants

View Source
const LoftUrl = "LOFT_URL"

Variables

View Source
var (
	ErrNoConfigLoaded = errors.New("no config loaded")
	ErrNotLoggedIn    = errors.New("not logged in")
)
View Source
var (
	ErrNoUrl = errors.New("no url found")
)

Functions

func BuildRoot

func BuildRoot(log *log.StreamLogger) *cobra.Command

BuildRoot creates a new root command from the

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.

func NewBackupCmd

func NewBackupCmd(globalFlags *flags.GlobalFlags) *cobra.Command

NewBackupCmd creates a new command

func NewCompletionCmd

func NewCompletionCmd(command *cobra.Command, globalFlags *flags.GlobalFlags) *cobra.Command

func NewLoginCmd

func NewLoginCmd(globalFlags *flags.GlobalFlags) *cobra.Command

NewLoginCmd creates a new open command

func NewLogoutCmd

func NewLogoutCmd(globalFlags *flags.GlobalFlags) *cobra.Command

NewLoginCmd creates a new open command

func NewRootCmd

func NewRootCmd(streamLogger *log.StreamLogger) *cobra.Command

NewRootCmd returns a new root command

func NewStartCmd

func NewStartCmd(globalFlags *flags.GlobalFlags) *cobra.Command

NewStartCmd creates a new command

func NewTokenCmd

func NewTokenCmd(globalFlags *flags.GlobalFlags) *cobra.Command

NewTokenCmd creates a new command

func NewUiCmd

func NewUiCmd(globalFlags *flags.GlobalFlags) *cobra.Command

func NewUpgradeCmd

func NewUpgradeCmd() *cobra.Command

NewUpgradeCmd creates a new upgrade command

Types

type BackupCmd

type BackupCmd struct {
	*flags.GlobalFlags
	Log       log.Logger
	Namespace string
	Filename  string
	Skip      []string
}

BackupCmd holds the cmd flags

func (*BackupCmd) Run

func (cmd *BackupCmd) Run(cobraCmd *cobra.Command, args []string) error

Run executes the functionality

type CompletionCmd

type CompletionCmd struct {
	*flags.GlobalFlags
	// contains filtered or unexported fields
}

CompletionCmd holds the cmd flags

func (*CompletionCmd) Run

func (cmd *CompletionCmd) Run(cobraCmd *cobra.Command, args []string) error

type LoginCmd

type LoginCmd struct {
	*flags.GlobalFlags
	Log         log.Logger
	AccessKey   string
	Insecure    bool
	DockerLogin bool
}

LoginCmd holds the login cmd flags

func (*LoginCmd) RunLogin

func (cmd *LoginCmd) RunLogin(ctx context.Context, args []string) error

RunLogin executes the functionality "loft login"

type LogoutCmd

type LogoutCmd struct {
	*flags.GlobalFlags

	Log log.Logger
}

LogoutCmd holds the logout cmd flags

func (*LogoutCmd) RunLogout

func (cmd *LogoutCmd) RunLogout(ctx context.Context, args []string) error

RunLogin executes the functionality "loft login"

type StartCmd

type StartCmd struct {
	start.Options
}

StartCmd holds the cmd flags

func (*StartCmd) Run

func (cmd *StartCmd) Run(ctx context.Context) error

Run executes the functionality "loft start"

type TokenCmd

type TokenCmd struct {
	*flags.GlobalFlags

	Project        string
	VirtualCluster string
	// Deprecated please use access keys instead
	DirectClusterEndpoint bool
	// contains filtered or unexported fields
}

TokenCmd holds the cmd flags

func (*TokenCmd) Run

func (cmd *TokenCmd) Run() error

Run executes the command

type UiCmd

type UiCmd struct {
	*flags.GlobalFlags

	Log log.Logger
}

UiCmd holds the ui cmd flags

func (*UiCmd) Run

func (cmd *UiCmd) Run(ctx context.Context, args []string) error

type UpgradeCmd

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

UpgradeCmd is a struct that defines a command call for "upgrade"

func (*UpgradeCmd) Run

func (cmd *UpgradeCmd) Run(cobraCmd *cobra.Command, args []string) error

Run executes the command logic

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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