command

package
Version: v0.0.0-...-fb2c256 Latest Latest
Warning

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

Go to latest
Published: Oct 30, 2020 License: Apache-2.0, Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var GlobalOpts = GlobalOptionsKey{
	// contains filtered or unexported fields
}

GlobalOpts is the convenience object for storing the fixed global conifguration (parameter) keys

View Source
var Version string = "N/A"

Version is the CLI version to be filled in by the build system

Functions

func CLICredentialManager

func CLICredentialManager(logger logger.Logger) credential.Manager

CLICredentialManager returns a credential.Manager configured using the CLI global options

func New

func New(log logger.Logger) *cobra.Command

New constructs a new root command for the kcp CLI.

func NewKubeconfigCmd

func NewKubeconfigCmd(log logger.Logger) *cobra.Command

NewKubeconfigCmd constructs a new instance of KubeconfigCommand and configures it in terms of a cobra.Command

func NewLoginCmd

func NewLoginCmd(log logger.Logger) *cobra.Command

NewLoginCmd constructs a new instance of LoginCommand and configures it in terms of a cobra.Command

func NewOrchestrationCmd

func NewOrchestrationCmd(log logger.Logger) *cobra.Command

NewOrchestrationCmd constructs a new instance of OrchestrationCommand and configures it in terms of a cobra.Command

func NewRuntimeCmd

func NewRuntimeCmd(log logger.Logger) *cobra.Command

NewRuntimeCmd constructs a new instance of RuntimeCommand and configures it in terms of a cobra.Command

func NewTaskRunCmd

func NewTaskRunCmd(log logger.Logger) *cobra.Command

NewTaskRunCmd constructs a new instance of TaskRunCommand and configures it in terms of a cobra.Command

func NewUpgradeCmd

func NewUpgradeCmd(log logger.Logger) *cobra.Command

NewUpgradeCmd constructs the upgrade command and all subcommands under the upgrade command

func NewUpgradeKymaCmd

func NewUpgradeKymaCmd(log logger.Logger) *cobra.Command

NewUpgradeKymaCmd constructs a new instance of UpgradeKymaCommand and configures it in terms of a cobra.Command

func SetGlobalOpts

func SetGlobalOpts(cmd *cobra.Command)

SetGlobalOpts configures the global parameters on the given root command

func SetOutputOpt

func SetOutputOpt(cmd *cobra.Command, opt *string)

SetOutputOpt configures the optput type option on the given command

func SetRuntimeTargetOpts

func SetRuntimeTargetOpts(cmd *cobra.Command, targetInputs *[]string, targetExcludeInputs *[]string)

SetRuntimeTargetOpts configures runtime target options on the given command

func ValidateGlobalOpts

func ValidateGlobalOpts() error

ValidateGlobalOpts checks the presence of the required global configuration parameters

func ValidateOutputOpt

func ValidateOutputOpt(opt string) error

ValidateOutputOpt checks whether the given optput type is one of the valid values

func ValidateTransformRuntimeTargetOpts

func ValidateTransformRuntimeTargetOpts(targetInputs []string, targetExcludeInputs []string, targetSpec *orchestration.TargetSpec) error

ValidateTransformRuntimeTargetOpts checks the validity of runtime target options, and transforms them for internal usage

Types

type GlobalOptionsKey

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

GlobalOptionsKey is the type for holding the configuration key for each global parameter

func (*GlobalOptionsKey) GardenerKubeconfig

func (keys *GlobalOptionsKey) GardenerKubeconfig() string

GardenerKubeconfig gets the gardener-kubeconfig global parameter

func (*GlobalOptionsKey) KEBAPIURL

func (keys *GlobalOptionsKey) KEBAPIURL() string

KEBAPIURL gets the keb-api-url global parameter

func (*GlobalOptionsKey) KubeconfigAPIURL

func (keys *GlobalOptionsKey) KubeconfigAPIURL() string

KubeconfigAPIURL gets the kubeconfig-api-url global parameter

func (*GlobalOptionsKey) OIDCClientID

func (keys *GlobalOptionsKey) OIDCClientID() string

OIDCClientID gets the oidc-client-id global parameter

func (*GlobalOptionsKey) OIDCClientSecret

func (keys *GlobalOptionsKey) OIDCClientSecret() string

OIDCClientSecret gets the oidc-client-secret global parameter

func (*GlobalOptionsKey) OIDCIssuerURL

func (keys *GlobalOptionsKey) OIDCIssuerURL() string

OIDCIssuerURL gets the oidc-issuer-url global parameter

type KubeconfigCommand

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

KubeconfigCommand represents an execution of the kcp kubeconfig command

func (*KubeconfigCommand) Run

func (cmd *KubeconfigCommand) Run(cobraCmd *cobra.Command) error

Run executes the kubeconfig command

func (*KubeconfigCommand) Validate

func (cmd *KubeconfigCommand) Validate() error

Validate checks the input parameters of the kubeconfig command

type LoginCommand

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

LoginCommand represents an execution of the kcp login command

func (*LoginCommand) Run

func (cmd *LoginCommand) Run(cobraCmd *cobra.Command) error

Run executes the login command

func (*LoginCommand) Validate

func (cmd *LoginCommand) Validate() error

Validate checks the input parameters of the login command

type OrchestrationCommand

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

OrchestrationCommand represents an execution of the kcp orchestrations command

func (*OrchestrationCommand) Run

func (cmd *OrchestrationCommand) Run(args []string) error

Run executes the orchestrations command

func (*OrchestrationCommand) Validate

func (cmd *OrchestrationCommand) Validate(args []string) error

Validate checks the input parameters of the orchestrations command

type RuntimeCommand

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

RuntimeCommand represents an execution of the kcp runtimes command

func (*RuntimeCommand) Run

func (cmd *RuntimeCommand) Run() error

Run executes the runtimes command

func (*RuntimeCommand) Validate

func (cmd *RuntimeCommand) Validate() error

Validate checks the input parameters of the runtimes command

type TaskRunCommand

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

TaskRunCommand represents an execution of the kcp taskrun command

func (*TaskRunCommand) Run

func (cmd *TaskRunCommand) Run() error

Run executes the taskrun command

func (*TaskRunCommand) Validate

func (cmd *TaskRunCommand) Validate() error

Validate checks the input parameters of the taskrun command

type UpgradeCommand

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

UpgradeCommand is the base type of all subcommands under the upgrade command. The type holds common attributes and methods inherited by all subcommands

func (*UpgradeCommand) SetUpgradeOpts

func (cmd *UpgradeCommand) SetUpgradeOpts(cobraCmd *cobra.Command)

SetUpgradeOpts configures the upgrade specific options on the given command

func (*UpgradeCommand) ValidateTransformUpgradeOpts

func (cmd *UpgradeCommand) ValidateTransformUpgradeOpts() error

ValidateTransformUpgradeOpts checks in the input upgrade options, and transforms them for internal usage

type UpgradeKymaCommand

type UpgradeKymaCommand struct {
	UpgradeCommand
}

UpgradeKymaCommand represents an execution of the kcp upgrade kyma command. Inherits fields and methods of UpgradeCommand

func (*UpgradeKymaCommand) Run

func (cmd *UpgradeKymaCommand) Run() error

Run executes the upgrade kyma command

func (*UpgradeKymaCommand) Validate

func (cmd *UpgradeKymaCommand) Validate() error

Validate checks the input parameters of the upgrade kyma command

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL