lang

package
v0.42.2 Latest Latest
Warning

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

Go to latest
Published: Nov 14, 2026 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Overview

Package lang holds the cli helping text

Index

Constants

View Source
const (
	// CmdDistroCreateShort create short
	CmdDistroCreateShort = "Creates a Cargoship Package from a given directory or the current directory"
	// CmdDistroCreateLong create long
	CmdDistroCreateLong = "Builds an offline distro package from a definition directory -- a distro.yaml and whatever sits beside it -- producing one compressed archive that carries everything a cluster needs: the engine's packages and binaries, the OCI images, the configuration templates, and the checksums over all of them.\n\n" +
		"The archive is fat on purpose. One package holds every architecture it targets, and the host's own architecture selects what gets uploaded at apply time, so a mixed fleet installs from a single file.\n\n" +
		"Everything the definition declares is fetched while this runs, which is the one step that needs a network. --registry-override and --file-override redirect those fetches to an internal mirror or to files staged on disk ahead of time, which is how a package is built where there is no route to the upstream hosts. A declared shasum is enforced either way.\n\n" +
		"--signing-key signs the package as it is built. --reproducible pins the recorded build time so that identical inputs produce a byte-identical archive."
	// CmdDistroPublishShort publish short
	CmdDistroPublishShort = "Publish the Cargoship Package to an OCI registry"
	// CmdDistroPublishLong publish long
	CmdDistroPublishLong = "Pushes a built package to an OCI registry, where 'cargoship apply' and 'cargoship pull' can read it by reference instead of by path. The package is uploaded as OCI artifacts, so any registry that stores them will hold it, and --oci-concurrency sets how many layers move at once.\n\n" +
		"The signature a package already carries is published with it. Passing --signing-key re-signs the package under a different key on the way out, which is how one built and signed in a development environment is re-signed for a production registry."
	// CmdPackageMirrorShort mirror short
	CmdPackageMirrorShort = "Publish a built package's images and files to an OCI registry"
	// CmdPackageMirrorLong mirror long
	CmdPackageMirrorLong = "Pushes what a package carries -- its images, and the files it stages -- into a registry as individually pullable content, so the mirror a fleet is already pointed at holds what its nodes will ask for.\n\n" +
		"This is not 'cargoship publish'. That uploads the package as one artifact, to be pulled back as a package. This unpacks it: each image is pushed under the same repository path and tag it had upstream with only the registry host swapped, because that is exactly what a node asks a mirror for once cargoship has written the mirror into its containerd configuration. An image the package carries for several architectures is pushed as an index, so the registry holds every architecture the package did.\n\n" +
		"Each file is pushed as a single-layer OCI artifact named after the file and tagged with a digest of the source URL the definition declared, which keeps two releases of the same filename apart.\n\n" +
		"Give the registry as an oci:// reference, optionally with a repository prefix for a registry that will not accept a push at its root. Give --config instead and the address is read from the registry proxy the cluster configuration declares, which is the same field cargoship writes into each host, so the two cannot disagree. Credentials come from the Docker configuration file, as they do for every other cargoship registry operation.\n\n" +
		"--from-zarf-state reads the destination and the push credentials from a zarf deployment's state instead. Its in-cluster registry sits at an address only a node can reach, so either add --config to tunnel the push through a node over ssh, or name an address this machine reaches.\n\n" +
		"A finished mirror records which package populated it, under cargoship:_mirror.NAME.VERSION, so that 'cargoship ls' can answer what a registry holds. The record is a few kilobytes and is written only once everything else has landed.\n\n" +
		"--publish adds the package itself, as 'cargoship publish --record' would have, once the mirror has landed. The two answer different questions -- what a node pulls at runtime, and what a consumer pulls to install with -- and a registry holding only the first is one a consumer cannot install from. An air gap generally wants both."
	// CmdPackageMirrorExample mirror example
	CmdPackageMirrorExample = "\n" +
		"# Mirror everything the package carries into a registry:\n" +
		"$ cargoship mirror ./cargoship-rke2-amd64-0.1.0.tar.zst oci://harbor.internal\n\n" +
		"# Mirror into the proxy the cluster configuration already declares:\n" +
		"$ cargoship mirror ./cargoship-rke2-amd64-0.1.0.tar.zst --config ./cluster.yaml\n\n" +
		"# Mirror only the images, over plain HTTP:\n" +
		"$ cargoship mirror ./cargoship-rke2-amd64-0.1.0.tar.zst oci://registry.internal:5000 --images --plain-http\n\n" +
		"# Mirror into a zarf deployment's in-cluster registry, tunnelled over ssh to a node:\n" +
		"$ cargoship mirror ./cargoship-rke2-amd64-0.1.0.tar.zst --from-zarf-state --config ./cluster.yaml\n"
	// CmdFlagClusterConfigRegistry cluster configuration flag, shared by mirror and ls
	CmdFlagClusterConfigRegistry = "`PATH` of a cluster configuration to read the registry from. See docs/guides/mirror-registry.md."
	// CmdPackageMirrorFlagImages mirror flag images
	CmdPackageMirrorFlagImages = "Mirror only the images the package carries. Mutually exclusive with --files; both are mirrored when neither is given."
	// CmdPackageMirrorFlagFiles mirror flag files
	CmdPackageMirrorFlagFiles = "Mirror only the files the package stages. Mutually exclusive with --images; both are mirrored when neither is given."
	// CmdFlagFromZarfState from-zarf-state flag, shared by mirror and ls
	CmdFlagFromZarfState = "Take the registry and its credentials from a zarf deployment. See docs/guides/mirror-registry.md."
	// CmdFlagViaKube registry target flag via-kube
	CmdFlagViaKube = "Tunnel the push through the api server to an in-cluster `SERVICE`, as namespace/service:port. Implies --from-zarf-state."
	// CmdFlagKubeContext kubeconfig context flag, shared by mirror and ls
	CmdFlagKubeContext = "" /* 126-byte string literal not displayed */
	// CmdPackageLsShort ls short
	CmdPackageLsShort = "List the cargoship packages mirrored into an OCI registry"
	// CmdPackageLsLong ls long
	CmdPackageLsLong = "Reads the record every 'cargoship mirror' leaves behind and reports which packages populated a registry, newest first. This is what a registry holds rather than what a cluster runs: two versions of one package can be mirrored side by side, and both are listed.\n\n" +
		"The registry is named the same three ways 'cargoship mirror' names it -- as an oci:// argument, with --config to read the proxy a cluster configuration declares, or with --from-zarf-state to read a zarf deployment's own registry, tunnelled over ssh when --config names the fleet.\n\n" +
		"Records live in one repository, so a listing is a single tag query and needs no more than a pull -- which is what makes this work on ghcr.io and Docker Hub, where a registry catalogue cannot be read at all. --name narrows it to one package. A listing is what was recorded, so content deleted from the registry by hand still appears."
	// CmdPackageLsExample ls example
	CmdPackageLsExample = "\n" +
		"# List what has been mirrored into a registry:\n" +
		"$ cargoship ls oci://harbor.internal\n\n" +
		"# List one package's versions, newest first:\n" +
		"$ cargoship ls oci://harbor.internal --name rke2\n\n" +
		"# List a zarf deployment's in-cluster registry, over ssh to a node:\n" +
		"$ cargoship ls --from-zarf-state --config ./cluster.yaml\n\n" +
		"# Machine-readable, for a script choosing a version:\n" +
		"$ cargoship ls oci://harbor.internal -o json\n"
	// CmdPackageMirrorFlagNoRecord mirror flag no-record
	CmdPackageMirrorFlagNoRecord = "Skip the record a finished mirror writes about itself, which is what makes `cargoship ls` able to see it."
	// CmdPackageMirrorFlagPublish mirror flag publish
	CmdPackageMirrorFlagPublish = "Also publish the package itself to the same registry, so a consumer can pull it. See docs/guides/mirror-registry.md."
	// CmdPackagePublishFlagRecord publish flag record
	CmdPackagePublishFlagRecord = "Record the published package so `cargoship ls` can find it and resolve the newest version. Off by default."
	// CmdPackageLsFlagName ls flag name
	CmdPackageLsFlagName = "`NAME` of one package to list the recorded versions of, instead of every package in the registry."
	// CmdPackagePullShort pull short
	CmdPackagePullShort = "Pulls a Cargoship package from a remote registry and saves it to the local filesystem"
	// CmdPackagePullLong pull long
	CmdPackagePullLong = "Downloads a package from an OCI registry or an https:// URL and writes it to the local filesystem as a single archive, so that it can be carried to a machine with no route to the registry it came from. An apply reads the same references directly, so pulling first is for staging rather than something an install needs.\n\n" +
		"--shasum checks the downloaded archive against a checksum you already hold, which is the check to use when the package is to be trusted on the strength of something other than its signature."
	// CmdPackagePullFlagShasum pull shasum flag
	CmdPackagePullFlagShasum = "Shasum of the package to pull."
	// CmdPackageImportShort import short
	CmdPackageImportShort = "Converts an OCI Image Layout archive into a native Cargoship package"
	// CmdPackageImportLong import long
	CmdPackageImportLong = "" /* 221-byte string literal not displayed */
	// CmdDistroApplyShort apply short
	CmdDistroApplyShort = "Apply a config file to bootstrap and upgrade a cluster"
	// CmdDistroApplyLong apply long
	CmdDistroApplyLong = "Bootstraps a cluster from a package and a cluster configuration, or upgrades one that is already running, by stepping through the apply phases against every host the configuration names. One command does both: the engine version already on each host is what tells an upgrade apart from an install, and a downgrade is refused rather than attempted, before any phase has written to a host. Pass --allow-downgrade when the move backwards is deliberate.\n\n" +
		"Cargoship opens every SSH connection itself, from the machine it runs on, and nothing is installed on a target host beyond what a phase uploads.\n\n" +
		"An apply never removes a node. A host deleted from the configuration leaves its node in the cluster and stops the run rather than having the difference reconciled, so that no machine is drained or uninstalled by a configuration edit alone. Pass --allow-unmanaged-nodes when the extra nodes were joined deliberately and cargoship should leave them alone.\n\n" +
		"This changes every host it is pointed at, so it needs --confirm. Pass --dry-run instead to connect to every host and run the preflight checks for real, reporting what the run would change without changing it."
	// CmdDistroPrepareShort prepare short
	CmdDistroPrepareShort = "Prepares the nodes, including restarting the node if new kernel modules are enabled"
	// CmdDistroPrepareLong prepare long
	CmdDistroPrepareLong = "Brings every host the cluster configuration names up to the prerequisites the package declares, without installing the engine: environment variables and sysctl settings, container-selinux on hosts with SELinux enabled, the fapolicyd rules the distro supplies, and the kernel modules the package asks for. A host that gained a module is rebooted, because the module has to be loaded before an apply can use it.\n\n" +
		"Running this is optional. An apply runs the same preparation phases itself, and this command exists so that the disruptive half can be done on its own schedule -- ahead of a maintenance window rather than inside it.\n\n" +
		"--hosts and --firewall each opt into rewriting a part of the host that cargoship otherwise leaves alone. The fapolicyd rules are not one of them: they are written wherever a host runs fapolicyd and the package carries rules for it.\n\n" +
		"This changes every host it is pointed at, so it needs --confirm. Pass --dry-run to report what it would change instead."
	// CmdDistroResetShort reset short
	CmdDistroResetShort = "Reset a cluster, stopping, uninstalling, and removing all data for an engine"
	// CmdDistroResetLong reset long
	CmdDistroResetLong = "Removes the engine and the data it wrote from every host the cluster configuration names. Each node is deleted from the cluster, drained first where that is enabled, then the engine's packages or binaries are uninstalled and the service manager is reloaded.\n\n" +
		"This is destructive and it backs nothing up. Nothing a workload kept on a host survives it, and no command puts the cluster back: what follows a reset is an apply, which bootstraps a new one.\n\n" +
		"--distro names the engine to remove. A reset loads no package, so it has nothing else to read the engine's identity from.\n\n" +
		"This needs --confirm. Pass --dry-run to report every host it would reset, and what it would do to each, without touching one."
	// CmdDistroKubeConfigShort kube-config short
	CmdDistroKubeConfigShort = "Get the admin kube-config for a control-plane node"
	// CmdDistroKubeConfigLong kube-config long
	CmdDistroKubeConfigLong = "Fetches the engine's admin credentials from the first control-plane node the cluster configuration names and merges them into a kubeconfig file. The file is created when it does not exist, and an existing one keeps every other cluster it already holds.\n\n" +
		"The server address is rewritten to the control-plane address the configuration declares, rather than the node the credentials came from, so the context keeps working when that node does not. The context is named after the cluster's metadata.name.\n\n" +
		"This changes no host -- it connects, reads, and writes a file locally -- so it needs no --confirm. The file written to is --kubeconfig, which defaults to KUBECONFIG when that is set and to the standard location otherwise."
	// CmdDistroEngineConfigSyncShort engine-config-sync short
	CmdDistroEngineConfigSyncShort = "" /* 150-byte string literal not displayed */
	// CmdDistroEngineConfigSyncLong engine-config-sync long
	CmdDistroEngineConfigSyncLong = "Writes the engine configuration a package and a cluster configuration describe -- registry mirrors and credentials, audit policy, and pod security -- to every host the configuration names, and restarts the engine only where what is on disk no longer matches. A node whose configuration already agrees is left running untouched.\n\n" +
		"This exists because those three settings are the ones that change without the engine version changing, and a full apply is a heavier way to deliver them. Where a restart is needed the node is drained first, and the nodes are worked through at the rate --work-concurrency allows, so a cluster stays serving while its configuration moves.\n\n" +
		"Registry credentials encrypted with Ansible Vault or age are decrypted here, and the keys for every one of them are checked before the first host is connected to.\n\n" +
		"This changes every host whose configuration has drifted, so it needs --confirm. Pass --dry-run to report which nodes would be restarted without restarting one."
	// CmdInstallFirewallUpdate install flag firewall
	CmdInstallFirewallUpdate = "Whether to update every host node's firewall configuration."
	// CmdInstallFlagConcurrency install flag concurrency
	CmdInstallFlagConcurrency = "Maximum number of hosts to configure in parallel, set to 0 for unlimited."
	// CmdInstallFlagConfig install flag config
	CmdInstallFlagConfig = "Config file used to bootstrap a cluster."
	// CmdInstallFlagResetDistro install flag config
	CmdInstallFlagResetDistro = "What type of distro that will be reset. Valid options are: 'rke2', 'k3s'."
	// CmdInstallFlagResetTargetHosts names specific hosts to reset
	CmdInstallFlagResetTargetHosts = "Hosts to delete and uninstall, by hostname or address. Repeatable. Defaults to every host in the configuration."
	// CmdInstallFlagKubeConfigDistro kube-config flag config
	CmdInstallFlagKubeConfigDistro = "What type of distro we will get the admin config from. Valid options are: 'rke2', 'k3s'."
	// CmdInstallFlagConfirm install flag confirm
	CmdInstallFlagConfirm = "Proceed with the run. Without it, a command that would change a host reports what it needs and stops."
	// CmdInstallFlagDryRun install flag dry run
	CmdInstallFlagDryRun = "Report what would be done without changing any host. Runs the preflight checks for real. Does not need --confirm."
	// CmdInstallFlagTimeout install flag timeout
	CmdInstallFlagTimeout = "Set the timeout for how long functions will last."
	// CmdInstallFlagValues install flag values
	CmdInstallFlagValues = "YAML values file overriding what the package ships, repeatable, later winning. See docs/guides/package-values.md."
	// CmdInstallFlagVaultPasswordFile install flag vault password file
	CmdInstallFlagVaultPasswordFile = "File holding the Ansible Vault password. Falls back to CARGOSHIP_VAULT_PASSWORD, then ANSIBLE_VAULT_PASSWORD."
	// CmdInstallFlagWorkerConcurrency install flag worker concurrency
	CmdInstallFlagWorkerConcurrency = "Workers to update in parallel, a count or a percentage. See docs/guides/profile-concurrency.md."
	// CmdInstallHostUpdate install flag host
	CmdInstallHostUpdate = "Whether to update every host node's /etc/hosts file."
	// CmdInstallAllowUnmanagedNodes install flag allow unmanaged nodes
	CmdInstallAllowUnmanagedNodes = "Continue when the cluster holds a node no host in the config accounts for. An apply never removes a node."
	// CmdInstallAllowDowngrade install flag allow downgrade
	CmdInstallAllowDowngrade = "Continue when a host runs an engine newer than the package carries. Refused by default; engines do not move back."
	// CmdInstallLabelNodes install flag label nodes
	CmdInstallLabelNodes = "Check and add the node-role.kubernetes.io/PROFILE label on nodes. Reads admin credentials off a controller."
	// CmdInstallKubeConfigPath install flag kubeconfig path
	CmdInstallKubeConfigPath = "Path of the kubeconfig to merge this cluster's admin creds into. Defaults to KUBECONFIG, else ~/.kube/config."
	// CmdInstallUpdateKubeConfig install flag update kubeconfig
	CmdInstallUpdateKubeConfig = "Whether to write the admin creds for this cluster to a kubeconfig file at all."
	// CmdFlagPlainHTTP replaces zlang.RootCmdFlagPlainHTTP, which spends 159 characters on the
	// caveat. Same meaning, one line in an 80-column terminal.
	CmdFlagPlainHTTP = "Allow OCI registry connections over HTTP instead of HTTPS. Reduces security; use only with reason."
	// CmdFlagInsecureSkipTLSVerify replaces zlang.RootCmdFlagInsecureSkipTLSVerify, for the same
	// reason as CmdFlagPlainHTTP.
	CmdFlagInsecureSkipTLSVerify = "Skip validating the registry's TLS certificate. Reduces security; use only with reason."
	// CmdPackageSignFlagOutput replaces zlang.CmdPackageSignFlagOutput, which spelled its default
	// out in prose. The default is shown by cobra, so it does not need saying twice.
	CmdPackageSignFlagOutput = "Where to write the signed package: a local directory, or an oci:// registry URL."
	// CmdPackageCreateFlagConfirm create flag confirm. Replaces zarf's
	// CmdPackagePublishFlagConfirm, which described publishing a package and a signing-key
	// password prompt -- create does neither, and cargoship has no such prompt anywhere.
	CmdPackageCreateFlagConfirm = "Build the package without asking for confirmation first."
	// CmdPackageCreateFlagContentStore create flag content store
	CmdPackageCreateFlagContentStore = "`PATH` of a content store to resolve images and files from instead of the network. See docs/guides/content-store.md."
	// CmdPackageCreateFlagHaulerStore create flag hauler store. Deprecated: superseded by
	// CmdPackageCreateFlagContentStore, and kept only for the deprecated --hauler-store flag.
	CmdPackageCreateFlagHaulerStore = "`PATH` of a hauler store to resolve images and files from instead of the network. See docs/guides/content-store.md."
	// CmdPackageCreateFlagRegistryOverride create flag registry override. It replaces zarf's
	// string of the same name, which describes the flag as applying to image pulls only --
	// cargoship also redirects an oci:// file source through it.
	CmdPackageCreateFlagRegistryOverride = "Redirect registry pulls, as SOURCE=TARGET registry prefixes. Repeatable. See docs/guides/registry-override.md."
	// CmdPackageCreateFlagFileOverride create flag file override
	CmdPackageCreateFlagFileOverride = "Redirect file downloads, as SOURCE=TARGET URL prefixes or a local directory. See docs/guides/file-override.md."
	// CmdPackageCreateFlagOutput create flag output
	CmdPackageCreateFlagOutput = "Where to write the package: a local directory, or an oci:// registry URL."
	// CmdPackageCreateFlagTag create flag tag
	CmdPackageCreateFlagTag = "The tag or version to override the package metadata version with."
	// CmdPackageFlagConcurrency deploy flag concurrency
	CmdPackageFlagConcurrency = "Number of concurrent layer operations when pulling or pushing images or packages to/from OCI registries."
	// CmdPackageFlagRetries publish flag retry
	CmdPackageFlagRetries = "Number of retries to perform for Cargoship's operations, such as package publishes."
	// CmdVersionLong version long
	CmdVersionLong = "Displays the version of the release that the current binary was built from."
	// CmdVersionShort version short
	CmdVersionShort = "Shows the version of the running binary"
	// CmdVersionOutputFormat version flag output format
	CmdVersionOutputFormat = "Output format. Valid options are: yaml, json."
	// CmdSha256SumShort sha256sum short
	CmdSha256SumShort = "Generates a SHA256SUM for the given file"
	// CmdSha256SumFlagExtractPath flag description
	CmdSha256SumFlagExtractPath = "Path inside an archive, or inside the layer --layer names, to checksum. See docs/guides/oci-file-source.md."
	// CmdSha256SumFlagLayer flag description
	CmdSha256SumFlagLayer = "For an oci:// reference, the layer to take by its image title annotation. See docs/guides/oci-file-source.md."
	// CmdSha256SumFlagArch flag description
	CmdSha256SumFlagArch = "For an oci:// index, the architecture whose manifest to read. Never defaulted. See docs/guides/oci-file-source.md."
	// CmdVaultShort vault short
	CmdVaultShort = "Encrypts and decrypts cluster configuration values with Ansible Vault or age"
	// CmdVaultLong vault long
	CmdVaultLong = "" /* 677-byte string literal not displayed */
	// CmdVaultEncryptShort vault encrypt short
	CmdVaultEncryptShort = "Encrypts a value with Ansible Vault or age, for use in a registry's user/pass/token fields"
	// CmdVaultEncryptLong vault encrypt long
	CmdVaultEncryptLong = "" /* 447-byte string literal not displayed */
	// CmdVaultEncryptFlagPasswordFile flag description
	CmdVaultEncryptFlagPasswordFile = "File holding the Ansible Vault password. Falls back to CARGOSHIP_VAULT_PASSWORD, then ANSIBLE_VAULT_PASSWORD."
	// CmdFlagAgeIdentityFile flag description
	CmdFlagAgeIdentityFile = "age identity file, or SSH private key, that decrypts credentials. Repeatable. See docs/guides/age-encryption.md."
	// CmdFlagAgeRecipient flag description
	CmdFlagAgeRecipient = "age recipient or SSH public key to encrypt credentials to. Repeatable. See docs/guides/age-encryption.md."
	// CmdFlagAgeRecipientsFile flag description
	CmdFlagAgeRecipientsFile = "File of public keys, one per line; an authorized_keys file works. See docs/guides/age-encryption.md."
	// CmdVaultFlagDryRun flag description, shared by every vault command that rewrites a file in place
	CmdVaultFlagDryRun = "Print the resulting document to stdout instead of writing it back to FILE."
	// CmdVaultEncryptPathShort vault encrypt-path short
	CmdVaultEncryptPathShort = "Encrypts the values a config file already holds at one or more YAML paths, in place"
	// CmdVaultEncryptPathLong vault encrypt-path long
	CmdVaultEncryptPathLong = "" /* 784-byte string literal not displayed */
	// CmdVaultEncryptPathFlagForce flag description
	CmdVaultEncryptPathFlagForce = "Encrypt the value even though it is encrypted already, wrapping it a second time."
	// CmdVaultEncryptFileShort vault encrypt-file short
	CmdVaultEncryptFileShort = "Encrypts every registry credential in a config file, in place"
	// CmdVaultEncryptFileLong vault encrypt-file long
	CmdVaultEncryptFileLong = "" /* 765-byte string literal not displayed */
	// CmdVaultEncryptFileFlagForce flag description
	CmdVaultEncryptFileFlagForce = "Encrypt values that are encrypted already, wrapping them a second time."
	// CmdVaultRekeyFlagNewPasswordFile flag description
	CmdVaultRekeyFlagNewPasswordFile = "File holding the Ansible Vault password to move to. Omit to re-salt under the current key. No environment fallback."
	// CmdVaultKeygenShort vault keygen short
	CmdVaultKeygenShort = "Generates an age key pair, or prints the public key of one you already hold"
	// CmdVaultKeygenLong vault keygen long
	CmdVaultKeygenLong = "" /* 901-byte string literal not displayed */
	// CmdVaultKeygenFlagOutput flag description
	CmdVaultKeygenFlagOutput = "Path to write the identity to, mode 0600. An existing file is never overwritten. Omit to write to stdout."
	// CmdVaultKeygenFlagPublicKey flag description
	CmdVaultKeygenFlagPublicKey = "Print the public keys in IDENTITY_FILE instead of generating a pair. Reads stdin when no file is given."
	// CmdVaultDecryptShort vault decrypt short
	CmdVaultDecryptShort = "Decrypts an Ansible Vault or age value, printing the plaintext"
	// CmdVaultDecryptLong vault decrypt long
	CmdVaultDecryptLong = "" /* 660-byte string literal not displayed */
	// CmdVaultDecryptPathShort vault decrypt-path short
	CmdVaultDecryptPathShort = "Decrypts the values a config file holds at one or more YAML paths, in place"
	// CmdVaultDecryptPathLong vault decrypt-path long
	CmdVaultDecryptPathLong = "" /* 704-byte string literal not displayed */
	// CmdVaultDecryptFileShort vault decrypt-file short
	CmdVaultDecryptFileShort = "Decrypts every registry credential in a config file, in place"
	// CmdVaultDecryptFileLong vault decrypt-file long
	CmdVaultDecryptFileLong = "" /* 395-byte string literal not displayed */
	// CmdVaultRekeyShort vault rekey short
	CmdVaultRekeyShort = "Re-wraps every encrypted registry credential in a config file, optionally under a new key"
	// CmdVaultRekeyLong vault rekey long
	CmdVaultRekeyLong = "" /* 963-byte string literal not displayed */
	// CmdInstallFlagReceiptPath flag description
	CmdInstallFlagReceiptPath = "Write a JSON record of the run to PATH. Takes the {command} and {timestamp} placeholders. It names every host."
	// CmdRedactReceiptShort redact-receipt short
	CmdRedactReceiptShort = "Rewrites a run receipt so it can be attached to an issue"
	// CmdRedactReceiptLong redact-receipt long
	CmdRedactReceiptLong = "" /* 849-byte string literal not displayed */
	// CmdRedactReceiptFlagOutput flag description
	CmdRedactReceiptFlagOutput = "Write the redacted receipt to this path instead of standard output. The file is created readable only by its owner."
	// CmdViperErrLoadingConfigFile error text
	CmdViperErrLoadingConfigFile = "failed to load config file"
	// RootCmdFlagLogFormat log format
	RootCmdFlagLogFormat = "Select a logging format. Defaults to 'console'. Valid options are: 'console', 'json', 'dev'."
	// RootCmdFlagLogLevel log level
	RootCmdFlagLogLevel = "Log level when running cargoship. One of: error, warn, info, debug."
	// RootCmdFlagVersion version flag. Registered explicitly rather than left to cobra, so that
	// it reaches the generated docs and does not claim the -v shorthand. See cmd/root.go.
	RootCmdFlagVersion = "Print the version of the running binary and exit."
	// RootCmdFlagNoColor no color
	RootCmdFlagNoColor = "Disable terminal color codes in logging and stdout prints."
	// RootCmdFlagLogFile log file
	RootCmdFlagLogFile = "Always write a full-verbosity debug log to a file, regardless of --log-level."
	// RootCmdShort root short
	RootCmdShort = "CLI for cargoship installs"
	// RootCmdLong root long. Bare "cargoship" previously printed a command list and nothing about
	// where settings come from, which is the first thing an operator needs and the one thing no
	// subcommand's help covers.
	RootCmdLong = "Builds offline Kubernetes distro packages, and runs the cluster lifecycle -- prepare, apply, kube-config, reset -- against target hosts over SSH. It runs from a management node and opens the connections itself; nothing is installed on a target host that a phase did not upload.\n\n" +
		"Settings come from flags, then the environment, then a config file, in that order of precedence. The config file is 'cargoship-config.yaml' -- YAML is the only format read, and '.yml' is accepted too -- looked for in the current directory and then $HOME/.zarf, or at the exact path in CARGOSHIP_CONFIG. Every key is also settable in the environment under the DISTRO_ prefix with dots as underscores, so '.distro.publish.signing_key' is DISTRO_DISTRO_PUBLISH_SIGNING_KEY.\n\n" +
		"Run 'cargoship validate --kind config <file>' to check a config file, and 'cargoship schema config' to write its JSON Schema for an editor."
	// RootCmdUse root use
	RootCmdUse = "cargoship COMMAND"
	// RootGroupInstallID subcommand for install id
	RootGroupInstallID = "install"
	// RootGroupInstallTitle subcommand for install title
	RootGroupInstallTitle = "Install Commands:"
	// RootGroupPackageID subcommand for package id
	RootGroupPackageID = "package"
	// RootGroupPackageTitle subcommand for package id
	RootGroupPackageTitle = "Package Commands:"
	// RootGroupConfigID subcommand for config id
	RootGroupConfigID = "config"
	// RootGroupConfigTitle subcommand for config title. These used to fall into cobra's
	// "Additional Commands" bucket, which read as leftovers rather than as the group an operator
	// authoring a configuration wants.
	RootGroupConfigTitle = "Configuration Commands:"
	// CmdPackageFlagVerify flag
	CmdPackageFlagVerify = "Verify the Cargoship package signature."
	// CmdPackageFlagSigningKey signing key flag
	CmdPackageFlagSigningKey = "Private key for signing: a file path or env://ENV_VAR, no cloud KMS. See docs/guides/signing-packages.md."
	// CmdPackagePublishFlagSigningKey publish signing key flag
	CmdPackagePublishFlagSigningKey = "Private key for signing or re-signing: a path or env://ENV_VAR, no cloud KMS. See docs/guides/signing-packages.md."
	// CmdPackagePublishFlagSigningKeyPassword publish signing key password flag. Replaces zarf's
	// string of the same name, which zarf 1.0.1 removed.
	CmdPackagePublishFlagSigningKeyPassword = "Password to the private key used for publishing packages."
	// CmdPackagePublishFlagConfirm publish flag confirm. Replaces zarf's string of the same name,
	// which zarf 1.0.1 removed, and which promised to skip a signing-key password prompt that
	// cargoship does not have.
	CmdPackagePublishFlagConfirm = "Publish the package without asking for confirmation first."
	// CmdPackageCreateFlagReproducible create flag reproducible
	CmdPackageCreateFlagReproducible = "Pin the recorded build time to a fixed value, so identical inputs produce a byte-identical package."
	// CmdSchemaShort schema short
	CmdSchemaShort = "Writes out a JSON Schema for one of cargoship's own file formats"
	// CmdSchemaLong schema long
	CmdSchemaLong = "" /* 1158-byte string literal not displayed */
	// CmdSchemaFlagOutput flag description
	CmdSchemaFlagOutput = "Path to write the schema to. Omit it to write to stdout."
	// CmdSchemaFlagPackage flag description
	CmdSchemaFlagPackage = "Graft a package's values schema onto spec.config.values; 'inventory' only. See docs/guides/package-values.md."

	// CmdCleanCacheShort clean-cache short
	CmdCleanCacheShort = "Reports what the shared cache holds, and removes it"
	// CmdCleanCacheLong clean-cache long
	CmdCleanCacheLong = "Reports every area of the shared cache with its size, then removes the content a build can fetch again. Nothing else reclaims it: the cache has no size limit and no expiry, so it grows for as long as definitions name new versions.\n\n" +
		"What is removed is content, not record. The downloaded files and the archives extracted from them, the image blobs, and the examples generator's assets all come back on the next run that wants them, at the cost of fetching them again. The run logs and the local dev fleet's base images are left alone: nothing regenerates a log, and a fleet image is a multi-gigabyte download owned by 'mage dev:vmImage' rather than by a package build.\n\n" +
		"Pass --older-than to keep the working set and drop what a definition has stopped naming, which is usually what is wanted on a machine still in use. Note that it cannot prune an image layout: that area is an index over shared blobs, so removing some of them by age would leave the index naming blobs that are gone. It is reported as skipped, and comes out whole when --older-than is not given.\n\n" +
		"An entry's age is when it was written, not when it was last used, so a long-lived entry still in use can fall outside the window and be fetched again. This changes nothing but the time the next build takes.\n\n" +
		"Nothing here touches a cluster or a host. Use --dry-run to see what would go."
	// CmdCleanCacheExample clean-cache example
	CmdCleanCacheExample = "\n" +
		"# Report what the cache holds and what would be removed, removing nothing\n" +
		"$ cargoship dev clean-cache --dry-run\n\n" +
		"# Remove every fetchable thing in it\n" +
		"$ cargoship dev clean-cache\n\n" +
		"# Keep anything fetched in the last fortnight\n" +
		"$ cargoship dev clean-cache --older-than 336h\n"
	// CmdCleanCacheFlagOlderThan clean-cache flag older-than
	CmdCleanCacheFlagOlderThan = "Only remove entries written longer ago than this Go duration, such as 336h. Omit to remove every fetchable area."
	// CmdCleanCacheFlagDryRun clean-cache flag dry-run
	CmdCleanCacheFlagDryRun = "Report what would be removed without removing it."
	// CmdDevShort dev short
	CmdDevShort = "Commands for working on a definition or on cargoship itself"
	// CmdDevLong dev long
	CmdDevLong = "Groups the commands that serve someone authoring a distro definition, or working on cargoship, rather than someone operating a fleet. They render a definition from templates, build and apply one in one step, report and reclaim the shared build cache, checksum an artifact, and make a run receipt safe to attach to a ticket.\n\n" +
		"They are grouped rather than sitting at the root because the root is the operator's surface -- create, apply, prepare, reset -- and a command that is only ever reached for while editing a definition or filing a bug does not belong in that list."
	// CmdDevApplyShort dev apply short
	CmdDevApplyShort = "Builds a distro definition and applies it in one step"
	// CmdDevApplyLong dev apply long
	CmdDevApplyLong = "Builds the distro definition in DIR and immediately runs the apply phases against it, without writing a package first. It is 'cargoship create' followed by 'cargoship apply' with the artifact between them left out.\n\n" +
		"That artifact is what makes the normal loop slow. A package is compressed on the way out of create and decompressed again on the way into apply, over bytes that never leave this machine, which on a package carrying a fleet's images is most of the wait. Here the build stays in its directory and the apply phases read it where it sits.\n\n" +
		"Everything after the build is the same code 'cargoship apply' runs, including values resolution, engine-configuration mapping and template rendering, so what reaches the hosts is what the built package would have put there. The checks that differ are the ones that have nothing left to check: a package's integrity and signature are verified when apply loads one because those bytes travelled, and here they were produced by this process a moment earlier. Nothing is signed either, so a run cannot stand in for a check that a release build would pass.\n\n" +
		"The images and files a definition declares are still fetched, and are still served from the shared cache when they are already in it, so a second run after an edit usually reaches the network for nothing new.\n\n" +
		"This changes every host it is pointed at, so it needs --confirm. Pass --dry-run instead to build the definition, connect to every host and run the preflight checks for real, reporting what the run would change without changing it."
	// CmdDevApplyExample dev apply example
	CmdDevApplyExample = "\n" +
		"# Build the definition in the current directory and apply it\n" +
		"$ cargoship dev apply --config ./inventory.yaml --confirm\n\n" +
		"# Build a definition elsewhere, reporting what it would change without changing it\n" +
		"$ cargoship dev apply ./distro-defs --config ./inventory.yaml --dry-run\n\n" +
		"# Resolve the content from a local content store instead of the network\n" +
		"$ cargoship dev apply ./distro-defs --config ./inventory.yaml --content-store ./haul.tar.zst --confirm\n"
	// CmdDevRenderShort render short
	CmdDevRenderShort = "Renders package definition templates into a distro.yaml and the files beside it"
	// CmdDevRenderLong render long
	CmdDevRenderLong = "Evaluates Go templates against one or more YAML values files and writes the result, which is how a fleet of package definitions that differ only in a version, an architecture or a CNI is kept as one template plus a small input file per package.\n\n" +
		"Each --template renders to its own base name with the '.tmpl' suffix dropped, so 'distro.yaml.tmpl' becomes 'distro.yaml' and 'values.yaml.tmpl' becomes 'values.yaml' in the --out directory. Every template renders against the same merged values, so a value that has to agree between a definition and the values beside it is written once.\n\n" +
		"The values files are merged in the order given, later files winning, and reach a template as its top-level context: a file setting 'version: 1.36.4' is addressed as '{{ .version }}'. The template functions are the ones a package's own values templates get -- the sprig set, minus the functions that read host state -- so a template cannot read the environment or resolve names. A value path that resolves to nothing is an error rather than a 'no value' placeholder in the output.\n\n" +
		"An output named 'distro.yaml' is checked against the package schema before anything is written, so a definition that renders but cannot be built is reported here rather than by 'cargoship create'. Pass --no-validate to write it anyway.\n\n" +
		"This is the same generator cargoship's own example packages under example/ are rendered with, with one difference: the digest helpers those templates use fetch and hash remote artifacts, and are not available here."
	// CmdDevRenderExample render example
	CmdDevRenderExample = "\n" +
		"# Render a definition from a template and an input file\n" +
		"$ cargoship dev render --template ./distro.yaml.tmpl --values ./v1.36.4.yaml --out ./packages/v1.36.4\n\n" +
		"# Render a definition and the values file beside it together\n" +
		"$ cargoship dev render -t ./distro.yaml.tmpl -t ./values.yaml.tmpl --values ./common.yaml --values ./v1.36.4.yaml -o ./packages/v1.36.4\n"
	// CmdDevRenderFlagTemplate flag description
	CmdDevRenderFlagTemplate = "Template to render, repeatable. Each one is written to the --out directory under its own name with '.tmpl' dropped."
	// CmdDevRenderFlagValues flag description
	CmdDevRenderFlagValues = "YAML file holding the values every template renders against, repeatable. Merged in the order given, later files winning."
	// CmdDevRenderFlagOut flag description
	CmdDevRenderFlagOut = "Directory to write the rendered files to. Created if it does not exist."
	// CmdDevRenderFlagNoValidate flag description
	CmdDevRenderFlagNoValidate = "Write a rendered distro.yaml without checking it against the package schema first."

	// CmdInventoryShort inventory short
	CmdInventoryShort = "Generates a cluster inventory from another source of truth"
	// CmdInventoryLong inventory long
	CmdInventoryLong = "" /* 260-byte string literal not displayed */
	// CmdInventoryFromAnsibleShort inventory from-ansible short
	CmdInventoryFromAnsibleShort = "Translates an Ansible inventory into a cluster inventory"
	// CmdInventoryFromAnsibleLong inventory from-ansible long
	CmdInventoryFromAnsibleLong = "Translates an inventory Ansible has already resolved into a Cluster document, deriving each host's role from the Ansible groups it belongs to.\n\n" +
		"This does not read an Ansible inventory file. Ansible resolves the inventory -- group membership, group_vars, host_vars, dynamic inventory plugins, and the precedence rules over all of them -- and this reads the resolved result: a JSON document holding 'groups', 'hostvars', an optional 'roleGroups' mapping, and the cluster-wide settings an Ansible inventory has no way to carry. The cargoship Ansible collection produces that document; write it by hand to reproduce a translation outside a playbook run.\n\n" +
		"By default the Ansible group named 'controller' supplies the control-plane nodes and the group named 'worker' supplies the rest. Set 'roleGroups' to map cargoship's roles onto the group names the inventory actually uses. A host in none of the mapped groups is left out, so a play's inventory may carry hosts that are not part of the cluster; a host in groups mapped to two different roles is an error.\n\n" +
		"Host order is not cosmetic. Controllers are written first, and the first controller in the document becomes the cluster leader.\n\n" +
		"Each host's connection details come from its Ansible variables -- ansible_host, ansible_user, ansible_port, ansible_ssh_private_key_file -- and everything cargoship needs beyond those comes from variables under a 'cargoship_' prefix. A 'cargoship_' variable cargoship does not read is an error rather than a value ignored, because a misspelled variable and an unset one are indistinguishable at install time.\n\n" +
		"The generated document is checked against the inventory schema before it is written. The output goes to stdout, or to --output. Ansible does not connect to the fleet: cargoship opens every SSH connection itself, from the node it runs on."
	// CmdInventoryFlagOutput flag description
	CmdInventoryFlagOutput = "Path to write the generated inventory to. Omit it to write to stdout."
	// CmdInventoryFlagName flag description
	CmdInventoryFlagName = "Cluster name, overriding the one in the input. It becomes metadata.name, and the context name in the kubeconfig."
	// CmdInventoryFlagLoadBalancer flag description
	CmdInventoryFlagLoadBalancer = "Control-plane address, overriding the one in the input. Cargoship adds it to the API server's TLS subject alternative names."

	// CmdValidateShort validate short
	CmdValidateShort = "Checks a cluster inventory, package definition, or config file against its schema"
	// CmdValidateLong validate long
	CmdValidateLong = "Checks one or more files against the JSON Schema cargoship generates for that file format, " +
		"reporting every problem rather than the first. Cargoship parses these files without strict key checking, " +
		"so a misspelled key is dropped rather than reported; this catches that, along with a wrong type and a value " +
		"outside an enumerated list. The schema is read from the binary, so no network access is needed.\n\n" +
		"The schema is chosen from the document's own 'kind' field. A cargoship config file declares no kind and has " +
		"to be named with --kind.\n\n" +
		"spec.config.values is untyped in the inventory schema, because its shape belongs to whichever package is " +
		"being installed. Pass --package to check it as well."
	// CmdValidateFlagKind flag description
	CmdValidateFlagKind = "Name the schema instead of reading the document's 'kind'. Required for a config file, which declares none."
	// CmdValidateFlagPackage flag description
	CmdValidateFlagPackage = "Check spec.config.values against a package's values schema; 'inventory' only. See docs/guides/package-values.md."

	// CmdDistroSignShort sign short
	CmdDistroSignShort = "Signs an existing Cargoship distro package"
	// CmdDistroSignLong sign long
	CmdDistroSignLong = "" /* 229-byte string literal not displayed */

	// CmdDistroVerifyShort verify short
	CmdDistroVerifyShort = "Verifies the signature on a Cargoship distro package"
	// CmdDistroVerifyLong verify long
	CmdDistroVerifyLong = "" /* 407-byte string literal not displayed */
)
View Source
const (
	// CmdDistroApplyExample apply example
	CmdDistroApplyExample = `` /* 968-byte string literal not displayed */

	// CmdDistroPrepareExample prepare example
	CmdDistroPrepareExample = `` /* 642-byte string literal not displayed */

	// CmdDistroResetExample reset example
	CmdDistroResetExample = `` /* 500-byte string literal not displayed */

	// CmdDistroKubeConfigExample kube-config example
	CmdDistroKubeConfigExample = `` /* 344-byte string literal not displayed */

	// CmdDistroEngineConfigSyncExample engine-config-sync example
	CmdDistroEngineConfigSyncExample = `` /* 781-byte string literal not displayed */

	// CmdDistroCreateExample create example
	CmdDistroCreateExample = `` /* 953-byte string literal not displayed */

	// CmdDistroPublishExample publish example
	CmdDistroPublishExample = `` /* 701-byte string literal not displayed */

	// CmdPackagePullExample pull example
	CmdPackagePullExample = `` /* 561-byte string literal not displayed */

	// CmdPackageImportExample import example
	CmdPackageImportExample = `` /* 297-byte string literal not displayed */

	// CmdDistroSignExample sign example
	CmdDistroSignExample = `` /* 818-byte string literal not displayed */

	// CmdDistroVerifyExample verify example
	CmdDistroVerifyExample = `` /* 292-byte string literal not displayed */

	// CmdSha256SumExample sha256sum example
	CmdSha256SumExample = `` /* 878-byte string literal not displayed */

	// CmdVaultEncryptExample vault encrypt example
	CmdVaultEncryptExample = `` /* 924-byte string literal not displayed */

	// CmdVaultEncryptPathExample vault encrypt-path example
	CmdVaultEncryptPathExample = `` /* 1029-byte string literal not displayed */

	// CmdVaultEncryptFileExample vault encrypt-file example
	CmdVaultEncryptFileExample = `` /* 778-byte string literal not displayed */

	// CmdVaultDecryptFileExample vault decrypt-file example
	CmdVaultDecryptFileExample = `` /* 866-byte string literal not displayed */

	// CmdVaultRekeyExample vault rekey example
	CmdVaultRekeyExample = `` /* 1010-byte string literal not displayed */

	// CmdVaultKeygenExample vault keygen example
	CmdVaultKeygenExample = `` /* 680-byte string literal not displayed */

	// CmdVaultDecryptExample vault decrypt example
	CmdVaultDecryptExample = `` /* 990-byte string literal not displayed */

	// CmdVaultDecryptPathExample vault decrypt-path example
	CmdVaultDecryptPathExample = `` /* 864-byte string literal not displayed */

	// CmdInventoryFromAnsibleExample inventory from-ansible example
	CmdInventoryFromAnsibleExample = `` /* 542-byte string literal not displayed */

	// CmdSchemaExample schema example
	CmdSchemaExample = `` /* 774-byte string literal not displayed */

	// CmdValidateExample validate example
	CmdValidateExample = `` /* 499-byte string literal not displayed */

	// CmdVersionExample version example
	CmdVersionExample = `` /* 207-byte string literal not displayed */

	// CmdRedactReceiptExample redact-receipt example
	CmdRedactReceiptExample = `` /* 231-byte string literal not displayed */

)

Variables

This section is empty.

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

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