commands

package
v1.3.1 Latest Latest
Warning

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

Go to latest
Published: Nov 10, 2026 License: Apache-2.0 Imports: 70 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package commands implements ZCP CLI cobra commands.

Index

Constants

View Source
const (
	NetworkTypeL2       = "L2"
	NetworkTypeIsolated = "Isolated"
	NetworkTypeVpc      = "Vpc"
)

Network types accepted by --network-type.

Variables

This section is empty.

Functions

func EnforceSubcommandErrors

func EnforceSubcommandErrors(root *cobra.Command)

EnforceSubcommandErrors walks the command tree and makes every command *group* (a command that only organizes subcommands and has no action of its own) reject an unknown subcommand with an actionable error, instead of cobra's default of silently printing the group's help with a success (exit 0) status. Silently printing help on a bad token hides the mistake and — because the exit code is 0 — lets scripts and CI treat a typo as success; every mainstream CLI (git, kubectl, docker, cargo) instead errors to stderr with a non-zero exit.

The error adapts to the group:

  • a group with a single subcommand points the user straight at that command (with its example), since there is no ambiguity about what they meant;
  • a group with several subcommands lists the valid subcommands so the user can choose, and points at --help for full usage and examples.

Running a group with no arguments still prints its help and exits 0.

func HideFlagEverywhere

func HideFlagEverywhere(root *cobra.Command, name string)

HideFlagEverywhere walks the command tree and marks the named local flag hidden on every command that declares it. Used to keep auto-resolved plumbing flags (e.g. --cloud-provider) out of help output while leaving them usable as an explicit override.

func NewACLCmd

func NewACLCmd() *cobra.Command

NewACLCmd returns the 'acl' cobra command.

func NewAffinityGroupCmd

func NewAffinityGroupCmd() *cobra.Command

NewAffinityGroupCmd returns the 'affinity-group' cobra command.

func NewAuthCmd

func NewAuthCmd() *cobra.Command

NewAuthCmd returns the 'auth' cobra command.

func NewAutoscaleCmd

func NewAutoscaleCmd() *cobra.Command

NewAutoscaleCmd returns the 'autoscale' cobra command.

func NewBackupCmd

func NewBackupCmd() *cobra.Command

NewBackupCmd returns the 'backup' cobra command for block storage backups.

func NewBillingCmd

func NewBillingCmd() *cobra.Command

NewBillingCmd returns the 'billing' cobra command group.

func NewBillingCycleCmd

func NewBillingCycleCmd() *cobra.Command

NewBillingCycleCmd returns the 'billing-cycle' cobra command.

func NewCloudProviderCmd

func NewCloudProviderCmd() *cobra.Command

NewCloudProviderCmd returns the 'cloud-provider' cobra command.

func NewCurrencyCmd

func NewCurrencyCmd() *cobra.Command

NewCurrencyCmd returns the 'currency' cobra command.

func NewDNSCmd

func NewDNSCmd() *cobra.Command

NewDNSCmd returns the 'dns' cobra command.

func NewDashboardCmd

func NewDashboardCmd() *cobra.Command

NewDashboardCmd returns the 'dashboard' cobra command.

func NewEgressCmd

func NewEgressCmd() *cobra.Command

NewEgressCmd returns the 'egress' cobra command.

func NewFirewallCmd

func NewFirewallCmd() *cobra.Command

NewFirewallCmd returns the 'firewall' cobra command.

func NewIPCmd

func NewIPCmd() *cobra.Command

NewIPCmd returns the 'ip' cobra command.

func NewISOCmd

func NewISOCmd() *cobra.Command

NewISOCmd returns the 'iso' cobra command.

func NewInstanceCmd

func NewInstanceCmd() *cobra.Command

NewInstanceCmd returns the 'instance' cobra command.

func NewKubernetesCmd

func NewKubernetesCmd() *cobra.Command

NewKubernetesCmd returns the 'kubernetes' cobra command.

func NewLoadBalancerCmd

func NewLoadBalancerCmd() *cobra.Command

NewLoadBalancerCmd returns the 'loadbalancer' cobra command.

func NewMarketplaceCmd

func NewMarketplaceCmd() *cobra.Command

NewMarketplaceCmd returns the 'marketplace' cobra command.

func NewMonitoringCmd

func NewMonitoringCmd() *cobra.Command

NewMonitoringCmd returns the 'monitoring' cobra command.

func NewNetworkCmd

func NewNetworkCmd() *cobra.Command

NewNetworkCmd returns the 'network' cobra command.

func NewObjectStorageCmd

func NewObjectStorageCmd() *cobra.Command

NewObjectStorageCmd returns the 'object-storage' cobra command.

func NewPermissionCmd

func NewPermissionCmd() *cobra.Command

NewPermissionCmd returns the 'permission' cobra command.

func NewPlanCmd

func NewPlanCmd() *cobra.Command

NewPlanCmd returns the 'plan' cobra command with subcommands for each STKCNSL service type.

func NewPortForwardCmd

func NewPortForwardCmd() *cobra.Command

NewPortForwardCmd returns the 'portforward' cobra command.

func NewProductCmd

func NewProductCmd() *cobra.Command

NewProductCmd returns the 'product' cobra command.

func NewProfileCmd

func NewProfileCmd() *cobra.Command

NewProfileCmd returns the 'profile' cobra command.

func NewProjectCmd

func NewProjectCmd() *cobra.Command

NewProjectCmd returns the 'project' cobra command.

func NewRegionCmd

func NewRegionCmd() *cobra.Command

NewRegionCmd returns the 'region' cobra command.

func NewRoleCmd

func NewRoleCmd() *cobra.Command

NewRoleCmd returns the 'role' cobra command.

func NewSSHKeyCmd

func NewSSHKeyCmd() *cobra.Command

NewSSHKeyCmd returns the 'ssh-key' cobra command.

func NewServerCmd

func NewServerCmd() *cobra.Command

NewServerCmd returns the 'server' cobra command.

func NewSnapshotCmd

func NewSnapshotCmd() *cobra.Command

NewSnapshotCmd returns the 'snapshot' cobra command for block storage snapshots.

func NewStorageCategoryCmd

func NewStorageCategoryCmd() *cobra.Command

NewStorageCategoryCmd returns the 'storage-category' cobra command.

func NewStoreCmd

func NewStoreCmd() *cobra.Command

NewStoreCmd returns the 'store' cobra command.

func NewSubUserCmd

func NewSubUserCmd() *cobra.Command

NewSubUserCmd returns the 'sub-user' cobra command.

func NewSupportCmd

func NewSupportCmd() *cobra.Command

NewSupportCmd returns the 'support' cobra command.

func NewTemplateCmd

func NewTemplateCmd() *cobra.Command

NewTemplateCmd returns the 'template' cobra command.

func NewUserProfileCmd

func NewUserProfileCmd() *cobra.Command

NewUserProfileCmd returns the 'profile-info' cobra command.

func NewVMBackupCmd

func NewVMBackupCmd() *cobra.Command

NewVMBackupCmd returns the 'vm-backup' cobra command.

func NewVMSnapshotCmd

func NewVMSnapshotCmd() *cobra.Command

NewVMSnapshotCmd returns the 'vm-snapshot' cobra command.

func NewVPCCmd

func NewVPCCmd() *cobra.Command

NewVPCCmd returns the 'vpc' cobra command.

func NewVPNCmd

func NewVPNCmd() *cobra.Command

NewVPNCmd returns the 'vpn' cobra command.

func NewVirtualRouterCmd

func NewVirtualRouterCmd() *cobra.Command

NewVirtualRouterCmd returns the 'virtual-router' cobra command.

func NewVolumeCmd

func NewVolumeCmd() *cobra.Command

NewVolumeCmd returns the 'volume' cobra command.

Types

This section is empty.

Jump to

Keyboard shortcuts

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