You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The above example uses secrets as plain strings. It is recommended to use a local secret store such as [Kubernetes secret store]({{% ref kubernetes-secret-store.md %}}) or a [local file]({{% ref file-secret-store.md %}}) to bootstrap secure key storage.
@@ -43,6 +45,7 @@ The above example uses secrets as plain strings. It is recommended to use a loca
43
45
| accessKey | Y | The AWS Access Key to access this resource | `"key"` |
44
46
| secretKey | Y | The AWS Secret Access Key to access this resource | `"secretAccessKey"` |
45
47
| sessionToken | N | The AWS session token to use | `"sessionToken"` |
48
+
| multipleKeyValuesPerSecret | N | When set to `"true"` allows for multiple key value pairs to be stored in a single secret. Defaults to `"false"` | `"true"` |
46
49
47
50
{{% alert title="Important" color="warning" %}}
48
51
When running the Dapr sidecar (daprd) with your application on EKS (AWS Kubernetes), if you're using a node/pod that has already been attached to an IAM policy defining access to AWS resources, you **must not** provide AWS access-key, secret-key, and tokens in the definition of the component spec you're using.
@@ -57,6 +60,46 @@ Query Parameter | Description
57
60
`metadata.version_id` | Version for the given secret key.
58
61
`metadata.version_stage`| Version stage for the given secret key.
59
62
63
+
## Configure multiple key-values per secret
64
+
65
+
The `multipleKeyValuesPerSecret` flag determines whether the secret store presents a single value or multiple key-value pairs per secret.
66
+
67
+
### Single value per secret
68
+
69
+
If `multipleKeyValuesPerSecret` is `false` (default), AWS Secrets Manager returns the secret value as-is. Given a secret named `database-credentials` with the following JSON content:
70
+
71
+
```json
72
+
{
73
+
"username": "admin",
74
+
"password": "secret123",
75
+
"host": "db.example.com"
76
+
}
77
+
```
78
+
79
+
Requesting this secret returns the entire JSON as a single value:
If `multipleKeyValuesPerSecret` is `true`, the secret store parses JSON content stored in AWS Secrets Manager and returns it as multiple key-value pairs.
91
+
92
+
Requesting the same `database-credentials` secret from above, the response breaks the JSON object into its own entries, allowing it to be parsed into multiple key-value pairs.
0 commit comments