...
The example below is optional. It shows how to build a custom module for Azure IoT Edge to read and decode Low Power IoT messages from a simulated LPWA IoT device. Follow the above link to:
- Install Docker.
- Download and install Visual Studio Code (VSC).
- Setup VSC with Azure IoT Tools.
- Setup Azure Container Registry in Azure Cloud.
- Create Module Project. For this step, please refer to instructions below on downloading the LoRaEdgeSolution from PCEI repo.
- Build and push solution to Azure Container Registry.
The steps below show how to build custom IoT module for Azure IoT Edge using "LoRaEdgeSolution" code from PCEI repo:
Download PCEI repo to the machine that has VSC and Docker installed (per above instructions):
Code Block | ||
---|---|---|
| ||
git clone "https://gerrit.akraino.org/r/pcei"
cd pcei
ls -l
total 0
drwxr-xr-x 8 oberzin staff 256 Dec 24 15:44 LoRaEdgeSolution
drwxr-xr-x 3 oberzin staff 96 Dec 24 15:44 iotclient
drwxr-xr-x 5 oberzin staff 160 Dec 24 15:44 locationAPI |
Using VSC open the LoRaEdgeSolution module that was downloaded from PCEI repo.
Add required credentials for Azure Container Registry (ACR) using .env file.
Build and push the solution to ACR as shown below. Righ-click on "deployment.template.json":
The docker image for the custom module should now be visible in Azure Cloud ACR:
Packaging Azure IoT Edge Public Cloud Edge (PCE) Application
...