components CLI command reference

Detailed information on the components CLI command

Description

List all Dapr components.

Supported platforms

Usage

  1. dapr components [flags]

Flags

NameEnvironment VariableDefaultDescription
—kubernetes, -kfalseList all Dapr components in a Kubernetes cluster (required)
—all-namespaces, -AtrueIf true, list all Dapr components in all namespaces
—help, -hPrint this help message
—name, -nThe components name to be printed (optional)
—namespaceList all components in the specified namespace
—output, -olistOutput format (options: json or yaml or list)

示例

  1. # List Dapr components in all namespaces in Kubernetes mode
  2. dapr components -k
  3. # List Dapr components in specific namespace in Kubernetes mode
  4. dapr components -k --namespace default
  5. # Print specific Dapr component in Kubernetes mode
  6. dapr components -k -n mycomponent
  7. # List Dapr components in all namespaces in Kubernetes mode
  8. dapr components -k --all-namespaces

Warning messages

This command can issue warning messages.

Root certificate renewal warning

If the mtls root certificate deployed to the Kubernetes cluster expires in under 30 days the following warning message is displayed:

  1. Dapr root certificate of your Kubernetes cluster expires in <n> days. Expiry date: <date:time> UTC.
  2. Please see docs.dapr.io for certificate renewal instructions to avoid service interruptions.