mirror of https://github.com/dapr/docs.git
Merging v0.11 to v1.0-rc2
This commit is contained in:
commit
71b4f3cbab
|
@ -8,13 +8,13 @@ assignees: ''
|
|||
---
|
||||
|
||||
**What content needs to be created or modified?**
|
||||
A clear and concise description of what the problem is. Ex. There should be docs on how pub/sub works...
|
||||
<!--A clear and concise description of what the problem is. Ex. There should be docs on how pub/sub works...-->
|
||||
|
||||
**Describe the solution you'd like**
|
||||
A clear and concise description of what you want to happen.
|
||||
<!--A clear and concise description of what you want to happen-->
|
||||
|
||||
**Where should the new material be placed?**
|
||||
Please suggest where in the docs structure the new content should be created.
|
||||
<!--Please suggest where in the docs structure the new content should be created-->
|
||||
|
||||
**Additional context**
|
||||
Add any other context or screenshots about the feature request here.
|
||||
<!--Add any other context or screenshots about the feature request here-->
|
||||
|
|
|
@ -8,16 +8,16 @@ assignees: ''
|
|||
---
|
||||
|
||||
**URL of the docs page**
|
||||
The URL(s) on docs.dapr.io where the typo occurs
|
||||
<!--The URL(s) on docs.dapr.io where the typo occurs-->
|
||||
|
||||
**How is it currently worded?**
|
||||
Please copy and paste the sentence where the typo occurs.
|
||||
<!--Please copy and paste the sentence where the typo occurs-->
|
||||
|
||||
**How should it be worded?**
|
||||
Please correct the sentence
|
||||
<!--Please correct the sentence-->
|
||||
|
||||
**Screenshots**
|
||||
If applicable, add screenshots to help explain your problem.
|
||||
<!--If applicable, add screenshots to help explain your problem-->
|
||||
|
||||
**Additional context**
|
||||
Add any other context about the problem here.
|
||||
<!--Add any other context about the problem here-->
|
||||
|
|
|
@ -8,31 +8,33 @@ assignees: AaronCrawfis
|
|||
---
|
||||
|
||||
**Describe the bug**
|
||||
A clear and concise description of what the bug is.
|
||||
<!--A clear and concise description of what the bug is.-->
|
||||
|
||||
**To Reproduce**
|
||||
**Steps to reproduce**
|
||||
<!--
|
||||
Steps to reproduce the behavior:
|
||||
1. Go to '...'
|
||||
2. Click on '....'
|
||||
3. Scroll down to '....'
|
||||
4. See error
|
||||
-->
|
||||
|
||||
**Expected behavior**
|
||||
A clear and concise description of what you expected to happen.
|
||||
<!--A clear and concise description of what you expected to happen.-->
|
||||
|
||||
**Screenshots**
|
||||
If applicable, add screenshots to help explain your problem.
|
||||
<!--If applicable, add screenshots to help explain your problem.-->
|
||||
|
||||
**Desktop (please complete the following information):**
|
||||
- OS: [e.g. iOS]
|
||||
- Browser [e.g. chrome, safari]
|
||||
- Version [e.g. 22]
|
||||
- OS: <!--[e.g. iOS]-->
|
||||
- Browser <!--[e.g. chrome, safari]-->
|
||||
- Version <!--[e.g. 22]-->
|
||||
|
||||
**Smartphone (please complete the following information):**
|
||||
- Device: [e.g. iPhone6]
|
||||
- OS: [e.g. iOS8.1]
|
||||
- Browser [e.g. stock browser, safari]
|
||||
- Version [e.g. 22]
|
||||
- Device: <!--[e.g. iPhone6]-->
|
||||
- OS: <!--[e.g. iOS8.1]-->
|
||||
- Browser <!--[e.g. stock browser, safari]-->
|
||||
- Version <!--[e.g. 22]-->
|
||||
|
||||
**Additional context**
|
||||
Add any other context about the problem here.
|
||||
<!--Add any other context about the problem here-->
|
||||
|
|
|
@ -8,16 +8,16 @@ assignees: ''
|
|||
---
|
||||
|
||||
**Describe the issue**
|
||||
A clear and concise description of what the bug is.
|
||||
<!--A clear and concise description of what the bug is-->
|
||||
|
||||
**URL of the docs**
|
||||
Paste the URL (docs.dapr.io/concepts/......) of the page
|
||||
<!--Paste the URL (docs.dapr.io/concepts/......) of the page-->
|
||||
|
||||
**Expected content**
|
||||
A clear and concise description of what you expected to happen.
|
||||
<!--A clear and concise description of what you expected to happen-->
|
||||
|
||||
**Screenshots**
|
||||
If applicable, add screenshots to help explain your problem.
|
||||
<!--If applicable, add screenshots to help explain your problem-->
|
||||
|
||||
**Additional context**
|
||||
Add any other context about the problem here.
|
||||
<!--Add any other context about the problem here-->
|
||||
|
|
|
@ -1,15 +1,20 @@
|
|||
Thank you for helping make the Dapr documentation better!
|
||||
|
||||
If you are a new contributor, please see the [this contribution guidance](https://docs.dapr.io/contributing/contributing-docs/) which helps keep the Dapr documentation readable, consistent and useful for Dapr users.
|
||||
**Please follow this checklist before submitting:**
|
||||
|
||||
Note that you must see that the suggested changes do not break the website [docs.dapr.io](https://docs.dapr.io). See [this overview](https://github.com/dapr/docs/blob/master/README.md#overview) on how to setup a local version of the website and make sure the website is built correctly.
|
||||
- [ ] [Read the contribution guide](https://docs.dapr.io/contributing/contributing-docs/)
|
||||
- [ ] Commands include options for Linux, MacOS, and Windows within codetabs
|
||||
- [ ] New file and folder names are globally unique
|
||||
- [ ] Page references use shortcodes instead of markdown or URL links
|
||||
- [ ] Images use HTML style and have alternative text
|
||||
- [ ] Places where multiple code/command options are given have codetabs
|
||||
|
||||
In addition, please fill out the following to help reviewers understand this pull request:
|
||||
|
||||
## Description
|
||||
|
||||
_Please explain the changes you've made_
|
||||
<!--Please explain the changes you've made-->
|
||||
|
||||
## Issue reference
|
||||
|
||||
_Please reference the issue this PR will close: #[issue number]_
|
||||
<!--Please reference the issue this PR will close: #[issue number]-->
|
||||
|
|
|
@ -3,11 +3,11 @@ name: Azure Static Web Apps CI/CD
|
|||
on:
|
||||
push:
|
||||
branches:
|
||||
- website
|
||||
- v0.11
|
||||
pull_request:
|
||||
types: [opened, synchronize, reopened, closed]
|
||||
branches:
|
||||
- website
|
||||
- v0.11
|
||||
|
||||
jobs:
|
||||
build_and_deploy_job:
|
||||
|
|
|
@ -7,7 +7,9 @@ description: >
|
|||
Introduction to the Distributed Application Runtime
|
||||
---
|
||||
|
||||
Dapr is a portable, event-driven runtime that makes it easy for enterprise developers to build resilient, stateless and stateful microservice applications that run on the cloud and edge and embraces the diversity of languages and developer frameworks.
|
||||
Dapr is a portable, event-driven runtime that makes it easy for any developer to build resilient, stateless and stateful applications that run on the cloud and edge and embraces the diversity of languages and developer frameworks.
|
||||
|
||||
{{< youtube 9o9iDAgYBA8 >}}
|
||||
|
||||
## Any language, any framework, anywhere
|
||||
|
||||
|
|
|
@ -8,43 +8,30 @@ description: "Overview of the Dapr Pub/Sub building block"
|
|||
|
||||
## Introduction
|
||||
|
||||
The [publish/subscribe pattern](https://en.wikipedia.org/wiki/Publish%E2%80%93subscribe_pattern) allows your microservices to communicate with each other purely by sending messages. In this system, the **producer** of a message sends it to a **topic**, with no knowledge of what service will receive the message. A messages can even be sent if there's no consumer for it.
|
||||
The [publish/subscribe pattern](https://en.wikipedia.org/wiki/Publish%E2%80%93subscribe_pattern) allows microservices to communicate with each other using messages. The **producer** sends messages to a **topic** without knowledge of what application will receive them. Similarly, a **consumer** will subscribe to the topic and receive its messages without any knowledge of what application produced these messages. This pattern is especially useful when you need to decouple microservices from one another.
|
||||
|
||||
Similarly, a **consumer** will receive messages from a topic without knowledge of what producer sent it. This pattern is especially useful when you need to decouple microservices from one another.
|
||||
|
||||
Dapr provides a publish/subscribe API that provides at-least-once guarantees and integrates with various message brokers implementations. These implementations are pluggable, and developed outside of the Dapr runtime in [components-contrib](https://github.com/dapr/components-contrib/tree/master/pubsub).
|
||||
The publish/subscribe API in Dapr provides an at-least-once guarantee and integrates with various message brokers and queuing systems. The specific implementation to your application is pluggable and configured externally at runtime. This approach removes the dependency from your application and, as a result, makes your application more portable. The complete list of available publish/subscribe implementations is available [here]({{< ref supported-pubsub >}}).
|
||||
|
||||
## Features
|
||||
|
||||
### Publish/Subscribe API
|
||||
|
||||
The API for Publish/Subscribe can be found in the [spec repo]({{< ref pubsub_api.md >}}).
|
||||
The publish/subscribe API is located in the [API reference]({{< ref pubsub_api.md >}}).
|
||||
|
||||
### At-Least-Once guarantee
|
||||
### Message Format
|
||||
|
||||
Dapr guarantees At-Least-Once semantics for message delivery.
|
||||
That means that when an application publishes a message to a topic using the Publish/Subscribe API, it can assume the message is delivered at least once to any subscriber when the response status code from that endpoint is `200`, or returns no error if using the gRPC client.
|
||||
To enable message routing and to provide additional context with each message Dapr uses the [CloudEvents 1.0 specification](https://github.com/cloudevents/spec/tree/v1.0) as its message format. Any message sent by an application to a topic using Dapr will automatically be "wrapped" in Cloud Events envelope, using `Content-Type` header value for `datacontenttype` attribute.
|
||||
|
||||
### Consumer groups and multiple instances
|
||||
Dapr implements the following Cloud Events fields:
|
||||
|
||||
The burden of dealing with concepts like consumer groups and multiple instances inside consumer groups is all catered for by Dapr.
|
||||
|
||||
When multiple instances of the same application ID subscribe to a topic, Dapr will make sure to deliver the message to only one instance. If two different applications with different IDs subscribe to a topic, at least one instance in each application receives a copy of the same message.
|
||||
|
||||
### Cloud events
|
||||
|
||||
Dapr follows the [CloudEvents 1.0 Spec](https://github.com/cloudevents/spec/tree/v1.0) and wraps any payload sent to a topic inside a Cloud Events envelope, using `Content-Type` header value for `datacontenttype` attribute.
|
||||
|
||||
The following fields from the Cloud Events spec are implemented with Dapr:
|
||||
- `id`
|
||||
- `source`
|
||||
- `specversion`
|
||||
- `type`
|
||||
- `datacontenttype` (Optional)
|
||||
|
||||
> Starting with Dapr v0.9, Dapr no longer wraps published content into CloudEvent if the published payload itself is already in CloudEvent format.
|
||||
* `id`
|
||||
* `source`
|
||||
* `specversion`
|
||||
* `type`
|
||||
* `datacontenttype` (Optional)
|
||||
|
||||
The following example shows an XML content in CloudEvent v1.0 serialized as JSON:
|
||||
|
||||
```json
|
||||
{
|
||||
"specversion" : "1.0",
|
||||
|
@ -58,11 +45,30 @@ The following example shows an XML content in CloudEvent v1.0 serialized as JSON
|
|||
}
|
||||
```
|
||||
|
||||
> Starting with v0.9 release, Dapr no longer wraps published content into CloudEvent if the published payload is already in the CloudEvent format.
|
||||
|
||||
### Message Subscription
|
||||
|
||||
Dapr allows two methods by which you can subscribe to topics: **declarative**, where a subscription is defined in an external file, and **programmatic**, where a subscription is defined in the user code. For more information see Dapr's documentation on [subscribing to a topic](https://docs.dapr.io/developing-applications/building-blocks/pubsub/howto-publish-subscribe/#step-2-subscribe-to-topics).
|
||||
|
||||
### Message Delivery
|
||||
|
||||
In principle, Dapr considers message successfully delivered when the subscriber responds with a non-error response after processing the message. For more granular control, Dapr's publish/subscribe API also provides explicit statuses, defined in the response payload, which the subscriber can use to indicate the specific handling instructions to Dapr (e.g. `RETRY` or `DROP`). For more information message routing see [Dapr publish/subscribe API documentation] ({{< ref "pubsub_api.md#provide-routes-for-dapr-to-deliver-topic-events" >}})
|
||||
|
||||
### At-Least-Once guarantee
|
||||
|
||||
Dapr guarantees at-least-once semantics for message delivery. That means that when an application publishes a message to a topic using the publish/subscribe API, Dapr ensures that this message will be delivered at least once to every subscriber.
|
||||
|
||||
### Consumer groups and multiple instances
|
||||
|
||||
The burden of dealing with concepts like consumer groups and multiple application instances using a single consumer group is all handled automatically by Dapr. When multiple instances of the same application (same IDs) subscribe to a topic, Dapr delivers each message to only one instance of that application. Similarly, if two different applications (different IDs) subscribe to the same topic, Dapr will deliver each message to only one instance of each application.
|
||||
|
||||
### Topic scoping
|
||||
|
||||
Limit which topics applications are able to publish/subscibe to in order to limit access to potentially sensitive data streams. Read [Pub/Sub scoping]({{< ref pubsub-scopes.md >}}) for more information.
|
||||
By default, all topics backing the Dapr publish/subscribe component (e.g. Kafka, Redis, RabbitMQ) are available to every application configured with that component. To limit which application can publish or subscribe to topics, Dapr provides topic scoping. See [publish/subscribe topic scoping]({{< ref pubsub-scopes.md >}}) for more information.
|
||||
|
||||
## Next steps
|
||||
|
||||
- Read the How-To guide on [publishing and subscribing]({{< ref howto-publish-subscribe.md >}})
|
||||
- Learn about [Pub/Sub scopes]({{< ref pubsub-scopes.md >}})
|
||||
- Read the [API reference]({{< ref pubsub_api.md >}})
|
||||
|
|
|
@ -36,7 +36,7 @@ Watch this [video](https://www.youtube.com/watch?v=OtbYCBt9C34&feature=youtu.be&
|
|||
|
||||
Now that the secret store is set up, you can call Dapr to get the secrets for a given key for a specific secret store.
|
||||
|
||||
For a full API reference, go [here](https://github.com/dapr/docs/blob/master/reference/api/secrets_api.md).
|
||||
For a full API reference, go [here]({{< ref secrets_api.md >}}).
|
||||
|
||||
Here are a few examples in different programming languages:
|
||||
|
||||
|
|
|
@ -31,7 +31,7 @@ spec:
|
|||
|
||||
In this example, the Redis component is only accessible to Dapr instances running inside the `production` namespace.
|
||||
|
||||
### Example of component namsespacing in self-hosted mode
|
||||
### Example of component namespacing in self-hosted mode
|
||||
|
||||
In self hosted mode, a developer can specify the namespace to a Dapr instance by setting the `NAMESPACE` environment variable.
|
||||
If the `NAMESPACE` environment variable is set, Dapr will not load any component that does not specify the same namespace in its metadata.
|
||||
|
@ -83,4 +83,4 @@ scopes:
|
|||
|
||||
## Example
|
||||
|
||||
<iframe width="560" height="315" src="https://www.youtube.com/embed/8W-iBDNvCUM?start=1763" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>
|
||||
<iframe width="560" height="315" src="https://www.youtube.com/embed/8W-iBDNvCUM?start=1763" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
---
|
||||
type: docs
|
||||
title: "How-To: Reference secret stores in components"
|
||||
title: "How-To: Reference secrets in components"
|
||||
linkTitle: "How-To: Reference secrets"
|
||||
weight: 300
|
||||
description: "How to securly reference secrets from a component definition"
|
||||
|
@ -18,9 +18,93 @@ When running in Kubernetes, if the `auth.secretStore` is empty, the Kubernetes s
|
|||
|
||||
Go to [this]({{< ref "howto-secrets.md" >}}) link to see all the secret stores supported by Dapr, along with information on how to configure and use them.
|
||||
|
||||
## Non default namespaces
|
||||
## Referencing secrets
|
||||
|
||||
If your Dapr enabled apps are using components that fetch secrets from non-default namespaces, apply the following resources to the namespace:
|
||||
While you have the option to use plain text secrets, this is not recommended for production:
|
||||
|
||||
```yml
|
||||
apiVersion: dapr.io/v1alpha1
|
||||
kind: Component
|
||||
metadata:
|
||||
name: statestore
|
||||
namespace: default
|
||||
spec:
|
||||
type: state.redis
|
||||
version: v1
|
||||
metadata:
|
||||
- name: redisHost
|
||||
value: localhost:6379
|
||||
- name: redisPassword
|
||||
value: MyPassword
|
||||
```
|
||||
|
||||
Instead create the secret in your secret store and reference it in the component definition:
|
||||
|
||||
```yml
|
||||
apiVersion: dapr.io/v1alpha1
|
||||
kind: Component
|
||||
metadata:
|
||||
name: statestore
|
||||
namespace: default
|
||||
spec:
|
||||
type: state.redis
|
||||
version: v1
|
||||
metadata:
|
||||
- name: redisHost
|
||||
value: localhost:6379
|
||||
- name: redisPassword
|
||||
secretKeyRef:
|
||||
name: redis-secret
|
||||
key: redis-password
|
||||
auth:
|
||||
secretStore: <SECRET_STORE_NAME>
|
||||
```
|
||||
|
||||
`SECRET_STORE_NAME` is the name of the configured [secret store component]({{< ref supported-secret-stores >}}). When running in Kubernetes and using a Kubernetes secret store, the field `auth.SecretStore` defaults to `kubernetes` and can be left empty.
|
||||
|
||||
The above component definition tells Dapr to extract a secret named `redis-secret` from the defined secret store and assign the value of the `redis-password` key in the secret to the `redisPassword` field in the Component.
|
||||
|
||||
## Example
|
||||
|
||||
### Referencing a Kubernetes secret
|
||||
|
||||
The following example shows you how to create a Kubernetes secret to hold the connection string for an Event Hubs binding.
|
||||
|
||||
1. First, create the Kubernetes secret:
|
||||
```bash
|
||||
kubectl create secret generic eventhubs-secret --from-literal=connectionString=*********
|
||||
```
|
||||
|
||||
2. Next, reference the secret in your binding:
|
||||
```yaml
|
||||
apiVersion: dapr.io/v1alpha1
|
||||
kind: Component
|
||||
metadata:
|
||||
name: eventhubs
|
||||
namespace: default
|
||||
spec:
|
||||
type: bindings.azure.eventhubs
|
||||
version: v1
|
||||
metadata:
|
||||
- name: connectionString
|
||||
secretKeyRef:
|
||||
name: eventhubs-secret
|
||||
key: connectionString
|
||||
```
|
||||
|
||||
3. Finally, apply the component to the Kubernetes cluster:
|
||||
```bash
|
||||
kubectl apply -f ./eventhubs.yaml
|
||||
```
|
||||
## Kubernetes permissions
|
||||
|
||||
### Default namespace
|
||||
|
||||
When running in Kubernetes, Dapr, during installtion, defines default Role and RoleBinding for secrets access from Kubernetes secret store in the `default` namespace. For Dapr enabled apps that fetch secrets from `default` namespace, a secret can be defined and referenced in components as shown in the example above.
|
||||
|
||||
### Non-default namespaces
|
||||
|
||||
If your Dapr enabled apps are using components that fetch secrets from non-default namespaces, apply the following resources to that namespace:
|
||||
|
||||
```yaml
|
||||
---
|
||||
|
@ -49,82 +133,8 @@ roleRef:
|
|||
apiGroup: rbac.authorization.k8s.io
|
||||
```
|
||||
|
||||
## Examples
|
||||
These resources grant Dapr permissions to get secrets from the Kubernetes secret store for the namespace defined in the Role and RoleBinding.
|
||||
|
||||
Using plain text:
|
||||
|
||||
```yml
|
||||
apiVersion: dapr.io/v1alpha1
|
||||
kind: Component
|
||||
metadata:
|
||||
name: statestore
|
||||
namespace: default
|
||||
spec:
|
||||
type: state.redis
|
||||
version: v1
|
||||
metadata:
|
||||
- name: redisHost
|
||||
value: localhost:6379
|
||||
- name: redisPassword
|
||||
value: MyPassword
|
||||
```
|
||||
|
||||
Using a Kubernetes secret:
|
||||
|
||||
```yml
|
||||
apiVersion: dapr.io/v1alpha1
|
||||
kind: Component
|
||||
metadata:
|
||||
name: statestore
|
||||
namespace: default
|
||||
spec:
|
||||
type: state.redis
|
||||
version: v1
|
||||
metadata:
|
||||
- name: redisHost
|
||||
value: localhost:6379
|
||||
- name: redisPassword
|
||||
secretKeyRef:
|
||||
name: redis-secret
|
||||
key: redis-password
|
||||
auth:
|
||||
secretStore: kubernetes
|
||||
```
|
||||
|
||||
The above example tells Dapr to use the `kubernetes` secret store, extract a secret named `redis-secret` and assign the value of the `redis-password` key in the secret to the `redisPassword` field in the Component.
|
||||
|
||||
### Creating a secret and referencing it in a Component
|
||||
|
||||
The following example shows you how to create a Kubernetes secret to hold the connection string for an Event Hubs binding.
|
||||
|
||||
First, create the Kubernetes secret:
|
||||
|
||||
```bash
|
||||
kubectl create secret generic eventhubs-secret --from-literal=connectionString=*********
|
||||
```
|
||||
|
||||
Next, reference the secret in your binding:
|
||||
|
||||
```yaml
|
||||
apiVersion: dapr.io/v1alpha1
|
||||
kind: Component
|
||||
metadata:
|
||||
name: eventhubs
|
||||
namespace: default
|
||||
spec:
|
||||
type: bindings.azure.eventhubs
|
||||
version: v1
|
||||
metadata:
|
||||
- name: connectionString
|
||||
secretKeyRef:
|
||||
name: eventhubs-secret
|
||||
key: connectionString
|
||||
```
|
||||
|
||||
Finally, apply the component to the Kubernetes cluster:
|
||||
|
||||
```bash
|
||||
kubectl apply -f ./eventhubs.yaml
|
||||
```
|
||||
|
||||
All done!
|
||||
{{% alert title="Note" color="warning" %}}
|
||||
In production scenario to limit Dapr's access to certain secret resources alone, you can use the `resourceNames` field. See this [link](https://kubernetes.io/docs/reference/access-authn-authz/rbac/#referring-to-resources) for further explanation.
|
||||
{{% /alert %}}
|
||||
|
|
|
@ -38,7 +38,7 @@ The above example uses secrets as plain strings. It is recommended to use a secr
|
|||
|
||||
### Create Blob
|
||||
|
||||
To perform a get blob operation, invoke the Azure Blob Storage binding with a `POST` method and the following JSON body:
|
||||
To perform a create blob operation, invoke the Azure Blob Storage binding with a `POST` method and the following JSON body:
|
||||
|
||||
```json
|
||||
{
|
||||
|
|
|
@ -17,6 +17,7 @@ The following table shows all the supported pod Spec annotations supported by Da
|
|||
| `dapr.io/config` | Tells Dapr which Configuration CRD to use
|
||||
| `dapr.io/log-as-json` | Setting this parameter to `true` outputs logs in JSON format. Default is `false`
|
||||
| `dapr.io/enable-profiling` | Setting this paramater to `true` starts the Dapr profiling server on port `7777`. Default is `false`
|
||||
| `dapr.io/api-token-secret` | Tells Dapr which Kubernetes secret to use for token based API authentication. By default this is not set.
|
||||
| `dapr.io/app-protocol` | Tells Dapr which protocol your application is using. Valid options are `http` and `grpc`. Default is `http`
|
||||
| `dapr.io/app-max-concurrency` | Limit the concurrency of your application. A valid value is any number larger than `0`
|
||||
| `dapr.io/app-ssl` | Tells Dapr to invoke the app over an insecure SSL connection. Applies to both HTTP and gRPC. Default is `false`.
|
||||
|
|
|
@ -76,10 +76,7 @@ Dapr supports zero downtime upgrades. The upgrade path includes the following st
|
|||
|
||||
### Upgrading the CLI
|
||||
|
||||
To upgrade the Dapr CLI, [download a release version](https://github.com/dapr/cli/releases) of the CLI that matches the Dapr runtime version.
|
||||
For example, if upgrading to Dapr 1.0.0-rc.x, download a CLI version of 1.0.0-rc.x.
|
||||
|
||||
After you downloaded the binary, it's recommended you put the CLI binary in your path.
|
||||
To upgrade the Dapr CLI, [download the latest version](https://github.com/dapr/cli/releases) of the CLI. After you downloaded the binary, it's recommended you put the CLI binary in your path.
|
||||
|
||||
### Updating the control plane
|
||||
|
||||
|
@ -141,12 +138,19 @@ NAME CHART VERSION APP VERSION DESCRIPTION
|
|||
dapr/dapr 1.0.0-rc.1 1.0.0-rc.1 A Helm chart for Dapr on Kubernetes
|
||||
```
|
||||
|
||||
The APP VERSION column tells us which Dapr runtime version is installed by the chart.
|
||||
The APP VERSION column tells us which Dapr runtime version is installed by the chart. Now, use the following command to upgrade Dapr to your desired runtime version providing a path to the certificate files you saved before:
|
||||
|
||||
Use the following command to upgrade Dapr to your desired runtime version providing a path to the certificate files you saved:
|
||||
> Remove `--set global.ha.enabled=true` if current Dapr installation has not been deployed in HA mode.
|
||||
|
||||
```bash
|
||||
helm upgrade dapr dapr/dapr --version <Dapr chart version> --namespace dapr-system --reset-values --set-file dapr_sentry.tls.root.certPEM=ca.crt --set-file dapr_sentry.tls.issuer.certPEM=issuer.crt --set-file dapr_sentry.tls.issuer.keyPEM=issuer.key
|
||||
helm upgrade dapr dapr/dapr \
|
||||
--version <Dapr chart version> \
|
||||
--namespace dapr-system \
|
||||
--reset-values \
|
||||
--set-file dapr_sentry.tls.root.certPEM=certs/ca.crt \
|
||||
--set-file dapr_sentry.tls.issuer.certPEM=certs/issuer.crt \
|
||||
--set-file dapr_sentry.tls.issuer.keyPEM=certs/issuer.key \
|
||||
--set global.ha.enabled=true
|
||||
```
|
||||
|
||||
Kubernetes now performs a rolling update. Wait until all the new pods appear as running:
|
||||
|
|
|
@ -11,7 +11,7 @@ type: docs
|
|||
|
||||
For self hosted mode, on running `dapr init`:
|
||||
|
||||
1. The following YAML file is created by default in `$HOME/dapr/config.yaml` (on Linux/Mac) or `%USERPROFILE%\dapr\config.yaml` (on Windows) and it is referenced by default on `dapr run` calls unless otherwise overridden `:
|
||||
1. The following YAML file is created by default in `$HOME/.dapr/config.yaml` (on Linux/Mac) or `%USERPROFILE%\.dapr\config.yaml` (on Windows) and it is referenced by default on `dapr run` calls unless otherwise overridden `:
|
||||
|
||||
* config.yaml
|
||||
|
||||
|
@ -24,8 +24,8 @@ metadata:
|
|||
spec:
|
||||
tracing:
|
||||
samplingRate: "1"
|
||||
zipkin:
|
||||
endpointAddress: "http://localhost:9411/api/v2/spans"
|
||||
zipkin:
|
||||
endpointAddress: "http://localhost:9411/api/v2/spans"
|
||||
```
|
||||
|
||||
2. The [openzipkin/zipkin](https://hub.docker.com/r/openzipkin/zipkin/) docker container is launched on running `dapr init` or it can be launched with the following code.
|
||||
|
@ -36,7 +36,7 @@ Launch Zipkin using Docker:
|
|||
docker run -d -p 9411:9411 openzipkin/zipkin
|
||||
```
|
||||
|
||||
3. The applications launched with `dapr run` will by default reference the config file in `$HOME/dapr/config.yaml` or `%USERPROFILE%\dapr\config.yaml` and can be overridden with the Dapr CLI using the `--config` param:
|
||||
3. The applications launched with `dapr run` will by default reference the config file in `$HOME/.dapr/config.yaml` or `%USERPROFILE%\.dapr\config.yaml` and can be overridden with the Dapr CLI using the `--config` param:
|
||||
|
||||
```bash
|
||||
dapr run --app-id mynode --app-port 3000 node app.js
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
---
|
||||
type: docs
|
||||
title: "Enable API token based authentication"
|
||||
title: "Enable token based API authentication"
|
||||
linkTitle: "API token auth"
|
||||
weight: 3000
|
||||
description: "Require every incoming API request to include an authentication token before allowing that request to pass through"
|
||||
|
@ -14,7 +14,7 @@ Dapr uses [JWT](https://jwt.io/) tokens for API authentication.
|
|||
|
||||
> Note, while Dapr itself is actually not the JWT token issuer in this implementation, being explicit about the use of JWT standard enables federated implementations in the future (e.g. OAuth2).
|
||||
|
||||
To configure APIs authentication, start by generating your token using any JWT token compatible tool (e.g. https://jwt.io/) and your secret.
|
||||
To configure API authentication, start by generating your token using any JWT token compatible tool (e.g. https://jwt.io/) and your secret.
|
||||
|
||||
> Note, that secret is only necessary to generate the token, and Dapr doesn't need to know about or store it
|
||||
|
||||
|
|
Loading…
Reference in New Issue