Trait lifecycle management
tanzu trait [command]
trait, traits, tr
create Create a trait with specified configuration
delete Delete a trait
generate Generate a trait manifest with specified configuration.
get Get details from a trait.
list List the traits in the current workspace.
--no-color deactivate color, bold, animations, and emoji output
--project name name of the project to use when creating or getting resources (default is project name from current Tanzu Platform context)
-h, --help help for trait
Create a trait with specified configuration.
Trait configuration options include:
tanzu trait create [name] [flags]
tanzu trait create --file trait.yaml
--dry-run print kubernetes resources to stdout rather than apply them to the cluster, messages normally on stdout will be sent to stderr
-f, --file file path file path containing the description of a single trait. Use value "-" to read from stdin
-h, --help help for create
-y, --yes accept all prompts
Delete a trait.
tanzu trait delete [name] [flags]
tanzu trait delete my-trait
-f, --file file path file path containing the description of a single trait to be deleted. Use value "-" to read from stdin
-h, --help help for delete
-y, --yes accept all prompts
Generate a trait manifest with specified configuration.
Trait configuration options include: - Packages to be included in the trait (can be provided multiple times)
tanzu trait generate [name] [flags]
tanzu trait generate NAME
tanzu trait generate NAME --package PACKAGE:CONSTRAINT
--exclude-all Add all the package values to "ExcludedKeys" list
-h, --help help for generate
-p, --package strings package to be included in the trait specification. (can be repeated, e.g., --package reference1 --package reference2)
Get details from a trait in the current workspace.
tanzu trait get [name] [flags]
tanzu trait get my-trait
-e, --export export Trait in yaml format
-h, --help help for get
-o, --output string output the Trait formatted. Supported formats: "json", "yaml", "yml"
List the traits in the current workspace.
tanzu trait list [flags]
tanzu trait list
tanzu trait list --output yaml
tanzu trait list --wide
-h, --help help for list
-o, --output string output the Traits formatted. Supported formats: "json", "yaml", "yml"
-w, --wide output the Trait list with additional information