This is an automated email from the ASF dual-hosted git repository. acosentino pushed a commit to branch azure-keyvault-docs-impr in repository https://gitbox.apache.org/repos/asf/camel.git
commit a8b0409b865a9d05a0d3fbd86128ebafe393af49 Author: Andrea Cosentino <anco...@gmail.com> AuthorDate: Fri Nov 29 10:17:29 2024 +0100 Camel-Azure-Key-Vault: Docs updated Signed-off-by: Andrea Cosentino <anco...@gmail.com> --- .../src/main/docs/azure-key-vault-component.adoc | 43 +++++++++++++++++++++- 1 file changed, 42 insertions(+), 1 deletion(-) diff --git a/components/camel-azure/camel-azure-key-vault/src/main/docs/azure-key-vault-component.adoc b/components/camel-azure/camel-azure-key-vault/src/main/docs/azure-key-vault-component.adoc index 860793598fa..283267dde0e 100644 --- a/components/camel-azure/camel-azure-key-vault/src/main/docs/azure-key-vault-component.adoc +++ b/components/camel-azure/camel-azure-key-vault/src/main/docs/azure-key-vault-component.adoc @@ -368,7 +368,48 @@ Now create the resource az eventhubs eventhub create --resource-group <resourceGroup> --namespace-name <eventhub-namespace> --name <eventhub-name> --cleanup-policy Delete --partition-count 15 ``` -In the Azure portal create a shared policy for the just created eventhub resource with "MANAGE" permissions and copy the connection string. +Now we need to create a shared policy to access Event Hub. + +``` +az eventhubs eventhub authorization-rule create --resource-group <resourceGroup> --namespace-name <eventhub-namespace> --eventhub-name <eventhub-name> --name <auth_rule_name> --rights Listen Send Manage +``` + +Now we are ready to get the connection string + +``` +az eventhubs eventhub authorization-rule keys list --resource-group <resourceGroup> --namespace-name <eventhub-namespace> --eventhub-name <eventhub-name> --name <auth_rule_name> +``` + +This will return the following output + +``` +{ + "keyName": "<auth_rule_name>", + "primaryConnectionString": "<primary_conn_string>", + "primaryKey": "<primary_key>", + "secondaryConnectionString": "<second_conn_string>", + "secondaryKey": "<secondary_key>" +} + +``` + +Substitute the connection string field with <primary_conn_string> as Event Hub connection string. + +Get back to the Azure Portal, and go to Key Vault service. + +Select the Key Vault just created. In the menu select "Events". + +Then Select the Event Hub icon. + +In the page that will open, define a name for the event subscription for example "keyvault-to-eh". + +In the System topic name field add "keyvault-to-eh-topic" for example. + +In the "Filter to Event Types" leave the default value of 9. + +In the configure endpoint section for Eventhub, in the Event Hub namespace section you should notice the namespace you've created through the AZ CLI, select that and in the Event Hub dropdown menu select the Event Hub you've created through the AZ CLI. Press confirm selection. + +Leave everything as it is and press "Create". You now have all the required parameters to set up the vault.