Azure

This article describes how to connect EdgeX-API to Azure by auto-provisioning in FUJI EdgeX Foundry's runtime environment in Windows 10.

Content

  • auto-provisioning batch file setup

  • Verify EdgeX Message

auto-provisioning batch file setup

  • Modify the tools\azure\auto_provisioning_cli\create_azure_iothub_edgex_fuji.bat file with your own Azure configuration

  • Execute the create_azure_iothub_edgex_fuji.bat in Command Prompt

  • The azure-cli will install automatically and please create a new Command Prompt to execute the

    create_azure_iothub_edgex_fuji.bat again after azure-cli installed

  • Please follow the instruction to open the URL in the browser, enter code, and sign-in Microsoft with your account to complete the installation

Verify EdgeX Message

  • In the Azure portal, verify the IoT Hub has received the EdgeX messages. Select Overview

> IoT Hub Usage. Refresh the page to update the chart. It might take a few seconds for it to show that the messages have been received.

  • You also can receive events from a JavaScript application that we made.

    • Cloning application from the repository: https://github.com/Advantech-EdgeX/web-apps-node-iot-hub-data-visualization

    • Open any editor, we choose Visual Studio Code here.

    • Open the application by selecting File > Open Folder in the editor.

    • Edit IotHubConnectionString and EventHubConsumerGroup in launch.json You can find the ConnectionString in create_azure_iothub_edgex_fuji.bat complete installed screen

  • In VS Code, press F5 to start debugging and open a browser to http://localhost:3000. It will display EdgeX

Last updated