Functions App deployed via Docker Image on Azure Container Registry do not appear

Kevin Villalobos 46 Reputation points
2021-05-18T16:13:35.133+00:00

Brief Summary:

Functions App deployed via Docker Image on Azure Container Registry do not appear when linking a custom allocation function to a Device Provisioning Service Enrollment Group. This does not happen when Functions App is deployed via code on the portal or .zip (view Figure 1).

97551-image.png

Details:

I have deployed a Device Provisioning Service on which I have defined an enrollment group. For provisioning the devices, I have defined a Custom Allocation Function. The custom allocation function is deployed to a docker image in Azure container registry. When I run the pcs-cli program for deploying the Azure services everything works fine (the custom allocation function is linked to the enrollment group and devices are provisioned by using that function (see Figure 2)).

97561-captura.png

However, if I try to manually link the function to the enrollment group (in the Azure Portal) it does not appear (see Figure 3).

97571-image.png

Workaround

I can manage to link the function again to the enrollment group via azure cli with the following command:

----------

az iot dps enrollment-group update -g $SOLUTION_NAME --dps-name $DPS_NAME --enrollment-id $ENROLLMENT_ID --iot-hubs $IOT_HUB_HOST --allocation-policy custom --webhook-url $ALLOCATION_FUNCTION --api-version 2019-03-31 --certificate-path ./certs/intermediate.cert.pem --initial-twin-tags "$TWIN_TAGS" --initial-twin-properties "$TWIN_PROPERTIES"

----------

Additional tests

I have been deploying both types of functions (docker image based and zip code based) several times via ARM templates and finally I have noticed that the only changing code line in the ARM template is the one that states:

"linuxFxVersion": "DOCKER|registry.azurecr.io/platformazurefunctions:testing" in docker image based deployment and

"linuxFxVersion": "DOTNET|3.1" on code based deployment.

Azure Container Registry
Azure Container Registry
An Azure service that provides a registry of Docker and Open Container Initiative images.
382 questions
Azure Functions
Azure Functions
An Azure service that provides an event-driven serverless compute platform.
4,211 questions
Azure IoT Hub
Azure IoT Hub
An Azure service that enables bidirectional communication between internet of things (IoT) devices and applications.
1,112 questions
{count} vote

Accepted answer
  1. QuantumCache 20,031 Reputation points
    2021-06-16T01:44:57.593+00:00

    Hello @Kevin Villalobos Thanks for bringing this to our product team's notice. We really appreciate the feedback which improves the product.

    Found the issue - turns out it's a UX bug.
    We have a Pull-Request that will fix this, we hope to release the fix to prod by End-Of-The Week.

    1 person found this answer helpful.

0 additional answers

Sort by: Most helpful