mirror of https://github.com/dapr/docs.git
Adding docs for dapr init changes (#2295)
* Adding docs for dapr init changes Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com> * addressing review comments Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com> * Addressing review comments Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com> * Update daprdocs/content/en/reference/cli/dapr-init.md Co-authored-by: Mark Fussell <markfussell@gmail.com>
This commit is contained in:
parent
681635ac9b
commit
e0d6e215aa
|
@ -5,12 +5,17 @@ linkTitle: "Preview features"
|
|||
weight: 4000
|
||||
description: "List of current preview features"
|
||||
---
|
||||
Preview features in Dapr are considered experimental when they are first released. These preview features require explicit opt-in in order to be used. The opt-in is specified in Dapr's configuration. See [How-To: Enable preview features]({{<ref preview-features>}}) for information more information.
|
||||
Preview features in Dapr are considered experimental when they are first released.
|
||||
|
||||
Runtime preview features require explicit opt-in in order to be used. The runtime opt-in is specified in a preview setting feature in Dapr's application configuration. See [How-To: Enable preview features]({{<ref preview-features>}}) for more information.
|
||||
|
||||
For CLI there is no explicit opt-in, just the version that this was first made available.
|
||||
|
||||
|
||||
## Current preview features
|
||||
| Feature | Description | Setting | Documentation |
|
||||
| ---------- |-------------|---------|---------------|
|
||||
| **Partition actor reminders** | Allows actor reminders to be partitioned across multiple keys in the underlying statestore in order to improve scale and performance. | `Actor.TypeMetadata` | [How-To: Partition Actor Reminders]({{< ref "howto-actors.md#partitioning-reminders" >}}) |
|
||||
| **Pub/Sub routing** | Allow the use of expressions to route cloud events to different URIs/paths and event handlers in your application. | `PubSub.Routing` | [How-To: Publish a message and subscribe to a topic]({{<ref howto-route-messages>}}) |
|
||||
| **ARM64 Mac Support** | Dapr CLI, sidecar, and Dashboard are now natively compiled for ARM64 Macs, along with Dapr CLI installation via Homebrew. | N/A | [Install the Dapr CLI]({{<ref install-dapr-cli>}}) |
|
||||
| Feature | Description | Setting | Documentation | Version introduced |
|
||||
| ---------- |-------------|---------|---------------|-----------------|
|
||||
| **Partition actor reminders** | Allows actor reminders to be partitioned across multiple keys in the underlying statestore in order to improve scale and performance. | `Actor.TypeMetadata` | [How-To: Partition Actor Reminders]({{< ref "howto-actors.md#partitioning-reminders" >}}) | v1.4 |
|
||||
| **Pub/Sub routing** | Allow the use of expressions to route cloud events to different URIs/paths and event handlers in your application. | `PubSub.Routing` | [How-To: Publish a message and subscribe to a topic]({{<ref howto-route-messages>}}) | v1.7 |
|
||||
| **ARM64 Mac Support** | Dapr CLI, sidecar, and Dashboard are now natively compiled for ARM64 Macs, along with Dapr CLI installation via Homebrew. | N/A | [Install the Dapr CLI]({{<ref install-dapr-cli>}}) | v1.5 |
|
||||
| **--image-registry** flag with Dapr CLI| In self hosted mode you can set this flag to specify any private registry to pull the container images required to install Dapr| N/A | [init CLI command reference]({{<ref "dapr-init.md#self-hosted-environment" >}}) | v1.7 |
|
||||
|
|
|
@ -33,10 +33,13 @@ dapr init [flags]
|
|||
| `--namespace`, `-n` | | `dapr-system` | The Kubernetes namespace to install Dapr in |
|
||||
| `--runtime-version` | | `latest` | The version of the Dapr runtime to install, for example: `1.0.0` |
|
||||
| `--slim`, `-s` | | `false` | Exclude placement service, Redis and Zipkin containers from self-hosted installation |
|
||||
|
||||
| `--image-registry` | | | Pulls container images required by Dapr from the given image registry |
|
||||
| N/A |DAPR_DEFAULT_IMAGE_REGISTRY| | In self hosted mode, it is used to specify the default container registry to pull images from. When its value is set to `GHCR` or `ghcr` it pulls the required images from Github container registry. To default to Docker hub as default, just unset this env variable.|
|
||||
### Examples
|
||||
|
||||
#### Self-hosted environment
|
||||
#### Self hosted environment
|
||||
|
||||
Install Dapr by pulling container images for Placement, Redis and Zipkin. By default these images are pulled from Docker Hub. To switch to Dapr Github container registry as the default registry, set the `DAPR_DEFAULT_IMAGE_REGISTRY` environment variable value to be `GHCR`. To switch back to Docker Hub as default registry, unset this environment variable.
|
||||
|
||||
```bash
|
||||
dapr init
|
||||
|
@ -54,6 +57,27 @@ Dapr can also run [Slim self-hosted mode]({{< ref self-hosted-no-docker.md >}})
|
|||
dapr init -s
|
||||
```
|
||||
|
||||
You can also specify a private registry to pull container images from. These images need to be published to private registries as shown below to enable Dapr CLI to pull them successfully via the `dapr init` command -
|
||||
|
||||
1. Dapr runtime container image(dapr) (Used to run Placement) - dapr/dapr:<version>
|
||||
2. Redis container image(rejson) - dapr/3rdparty/rejson
|
||||
3. Zipkin container image(zipkin) - dapr/3rdparty/zipkin
|
||||
|
||||
> All the required images used by Dapr needs to be under the`dapr` path.
|
||||
|
||||
> The 3rd party images have to be published under `dapr/3rdparty` path.
|
||||
|
||||
> image-registy uri follows this format - `docker.io/<username>`
|
||||
|
||||
```bash
|
||||
dapr init --image-registry docker.io/username
|
||||
```
|
||||
This command resolves the complete image URI as shown below -
|
||||
1. Placement container image(dapr) - docker.io/username/dapr/dapr:<version>
|
||||
2. Redis container image(rejson) - docker.io/username/dapr/3rdparty/rejson
|
||||
3. zipkin container image(zipkin) - docker.io/username/dapr/3rdparty/zipkin
|
||||
|
||||
|
||||
#### Kubernetes environment
|
||||
|
||||
```bash
|
||||
|
|
|
@ -17,4 +17,6 @@ The following table lists the environment variables used by the Dapr runtime, CL
|
|||
| DAPR_GRPC_PORT | Your application | The gRPC port that the Dapr sidecar is listening on. Your application should use this variable to connect to Dapr sidecar instead of hardcoding the port value. Set by the Dapr CLI run command for self hosted or injected by the dapr-sidecar-injector into all the containers in the pod. |
|
||||
| DAPR_METRICS_PORT | Your application | The HTTP [Prometheus]({{< ref prometheus >}}) port that Dapr sends its metrics information to. Your application can use this variable to send its application specific metrics to have both Dapr metrics and application metrics together. See [metrics-port]({{< ref arguments-annotations-overview>}}) for more information |
|
||||
| DAPR_API_TOKEN | Dapr sidecar | The token used for Dapr API authentication for requests from the application. Read [enable API token authentication in Dapr]({{< ref api-token >}}) for more information. |
|
||||
| NAMESPACE | Dapr sidecar | Used to specify a component's [namespace in self-hosted mode]({{< ref component-scopes >}}) |
|
||||
| NAMESPACE | Dapr sidecar | Used to specify a component's [namespace in self-hosted mode]({{< ref component-scopes >}})|
|
||||
| DAPR_DEFAULT_IMAGE_REGISTRY | Dapr CLI | In self hosted mode, it is used to specify the default container registry to pull images from. When its value is set to `GHCR` or `ghcr` it pulls the required images from Github container registry. To default to Docker hub as default, just unset this env variable.|
|
||||
|
||||
|
|
Loading…
Reference in New Issue