dapr / dapr/dotnet-sdk

how to load the azureCertificateFile

Open
#1,232 2 comments 0 reactions 0 assignees View on GitHub
area/client/secrets
Dominant language
C#
Stars
1.2k
Forks
378
Avg merge
1d 22h
Merged PRs (30d)
5

Description

## Ask your question here
Hi I am having problems loading the azureCertificateFile pfx file for the azure keyVault component locally , I can get the file to load .

what's the right format to add on the path value ?

storesecret.yaml

```
apiVersion: dapr.io/v1alpha1
kind: Component
metadata:
name: coresecretstore

spec:
type: secretstores.azure.keyvault
version: v1
metadata:
- name: vaultName
value: srmdev-container-core
- name: azureTenantId
value: **************************
- name: azureClientId
value : *************************
- name: azureCertificateFile
value: \srmdev-container-core-SRMDEVContainerKeyVaultAccess-20240209.pfx
```

Error
`time="2024-02-09T15:11:51.416171264Z" level=error msg="Error getting secret: ChainedTokenCredential: failed to acquire a token.\nAttempted credentials:\n\tmanaged identity\n\tAzureCLICredential: fork/exec /bin/sh: no such file or directory" app_id=project-reporting-service instance=5deedd416f9f scope=dapr.runtime type=log ver=1.12.0`

the certificate is located in the same folder where the yaml is.

Project Folder

![image](https://github.com/dapr/dotnet-sdk/assets/1914468/041dcdd9-74cf-4a46-8811-b0195e74db24)

Thanks

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.