[英]Retrieve key vault in web activity in Azure Data Factory
I am new to Azure Data Factory and I am now stuck at last step to finish my current task.我是 Azure 数据工厂的新手,现在我被困在完成当前任务的最后一步。
There are few REST API's that I need to call from ADF using Web Activity but before I make to REST API POST call, in this POST call I need to pass user credentials to be fetched from key vault and passing into BODY section. There are few REST API's that I need to call from ADF using Web Activity but before I make to REST API POST call, in this POST call I need to pass user credentials to be fetched from key vault and passing into BODY section. Once this POST request is issued I need to get authentication token from that server, hence as it is working in hard coded fashion.
发出此 POST 请求后,我需要从该服务器获取身份验证令牌,因此它以硬编码方式工作。 But now I want to fetch userId and password from Azure Key Vault and I then need to pass it to Web Activity.
但现在我想从 Azure Key Vault 获取用户 ID 和密码,然后我需要将其传递给 Web 活动。
NOTE: I do not want to use MSI option.注意:我不想使用 MSI 选项。
Could you please help on retrieving userId and password from Azure Key Vault for Web Activity to pass this as part of authentication?您能否帮助从 Azure Key Vault for Web Activity 检索用户 ID 和密码,以通过此作为身份验证的一部分?
You can follow these steps to achieve what you want:您可以按照以下步骤来实现您想要的:
I think you know how to add keyvault value, so I just show how to give the access authority.我想你知道如何添加 keyvault 值,所以我只是展示如何授予访问权限。
And choose 'Add'.并选择“添加”。 And dont foeget to save the edit.
并且不要忘记保存编辑。
Then, you can use a Set variable activity to get the value.然后,您可以使用 Set 变量活动来获取值。
The value of the activity is @activity('yourwebactivityname').output.value
活动的值为
@activity('yourwebactivityname').output.value
This is my pipeline:这是我的管道:
And I can get the value:我可以得到价值:
For more information, please have a look of the below document:有关更多信息,请查看以下文档:
https://docs.microsoft.com/en-us/azure/data-factory/how-to-use-azure-key-vault-secrets-pipeline-activities https://docs.microsoft.com/en-us/azure/data-factory/how-to-use-azure-key-vault-secrets-pipeline-activities
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.