commands

package
v0.33.16 Latest Latest
Warning

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

Go to latest
Published: Sep 11, 2026 License: Apache-2.0 Imports: 58 Imported by: 0

Documentation

Index

Constants

View Source
const DeliveryKitCommandName = "delivery-kit"

DeliveryKitCommandName is the top-level command name for the built-in werf re-skin. A plugin contract uses this same name to depend on delivery-kit while it ships as a built-in command rather than a standalone plugin.

Variables

View Source
var HelpUsername = "user"

Functions

func NewDeliveryCommand

func NewDeliveryCommand(ctx context.Context) *cobra.Command

NewDeliveryCommand builds the built-in werf re-skin under the root context. It returns nil only on a path that has already asked for termination, which onShutdown turns into a process exit before the caller sees the nil.

func NewHelpJSONCommand added in v0.20.9

func NewHelpJSONCommand(rootCmd *cobra.Command) *cobra.Command

func NewKubectlCommand

func NewKubectlCommand() *cobra.Command

func NewLoginCommand

func NewLoginCommand() *cobra.Command

func NewRootContext added in v0.33.15

func NewRootContext() context.Context

NewRootContext returns the process-wide graceful-termination context that the whole d8 command tree runs under: it installs the SIGINT/SIGTERM handler that Execute's graceful.Terminate and telemetry shutdown depend on, and carries the werf logger.

It is separate from NewDeliveryCommand because the context is root infrastructure, still required when an installed plugin serves `delivery-kit` and the built-in werf tree is never constructed.

func NewStrongholdCommand

func NewStrongholdCommand() *cobra.Command

func NewVirtualizationCommand

func NewVirtualizationCommand() *cobra.Command

func ReplaceCommandName

func ReplaceCommandName(from, to string, c *cobra.Command) *cobra.Command

func StrongholdSubcommands added in v0.29.29

func StrongholdSubcommands() []*cobra.Command

StrongholdSubcommands builds a cobra command tree from the vault CLI command registry (via CommandSynopses). This keeps synopses in sync with initCommands and respects build tags (e.g. clionly omits server/agent). Cobra exposes the structure to help and help-json; execution still goes through vaultcommand.Run.

Types

type CommandInfo

type CommandInfo struct {
	Name            string              `json:"name,omitempty"`
	Description     string              `json:"description"`
	LongDescription string              `json:"longDescription,omitempty"`
	Version         string              `json:"version,omitempty"`
	Aliases         []string            `json:"aliases"`
	Flags           map[string]FlagInfo `json:"flags"`
	Subcommands     []CommandInfo       `json:"subcommands"`
}

type FlagInfo

type FlagInfo struct {
	Description string `json:"description"`
	Short       string `json:"shorthand"`
	Global      bool   `json:"global"`
}

Jump to

Keyboard shortcuts

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