IoT Edge : device can't download my module from Azure Container Registry but it can from dockerhub

可紊 提交于 2019-12-02 05:24:14

Your Azure Container Registry is private. Hence, you need to add the credentials for it in order for the edgeAgent to be download images from private registries:

  • Through the Azure Portal: In the first step of "Set Modules"

  • When done through deployments in Visual Studio Code:

"In the VS Code explorer, open the .env file. Update the fields with the username and password values that you copied from your Azure container registry." (https://docs.microsoft.com/en-us/azure/iot-edge/tutorial-c-module#add-your-registry-credentials)

For your issue, you can use the command docker login -u <ACR username> -p <ACR password> <ACR login server> which shows in the example you posted. About the authentication of Azure Container Registry, there are two ways you can choose.

One is that use the user and password which shows in your ACR on the Azure portal.

Another is that you can use the Azure Service Principal, you can set the permission for the user. Follow document Azure Container Registry authentication with service principals. I would suggest this way much more than the first because it's safer.

It's just an advice. Hope this will help you and if you need more help please show me the message.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!