none
IoT Edge - Send Docker Image to Edge Device Fails RRS feed

  • Question

  • I am trying to create an edge device. I followed the example and had the simulated temperature sensor working on my windows 10 VM correctly which was deployed from the Portal.

    I am now trying to take a docker image that I have and deploy to the windows 10 VM as an IoT Edge Device. In the Portal, I clicked on IoT Edge and then created a device. After it was created, I clicked on the device and went to Set Modules where I created a new Deployment Module - IoT Edge Module and filled out all the details. I am using a docker image so for Image URI I entered https://hub.docker.com/r/myRepo/myImage where myRepo and myImage had the actual names in it. I also setup container options and environment variables. This is a public docker repo.

    When I run iotedge list on my Windows 10 VM I only get edgeAgent and not edgeHub and my other module I created that has the docker container in it.

    Going back in and clicking IoT Edge from the portal, I see an error on my IoT Device that states: "400 - The deployment configuration is malformed or invalid"

    Any help is greatly appreciated. Thank you!


    Monday, January 7, 2019 3:32 PM

All replies

  • Hi,

    Can you point us to the tutorial you are following?

    For what you are trying to achieve I would start here: Tutorial: Develop a C# IoT Edge module and deploy to your simulated device

    Thanks!

    Monday, January 7, 2019 3:41 PM
    Moderator
  • I followed this link ( https://docs.microsoft.com/en-us/azure/iot-edge/quickstart ) for getting my windows 10 vm setup to be able to be deployed to from the Portal. Once this was successful, I could not find any documents that showed me how to deploy a Docker container so I used the steps above that I wrote out to try and get it to work. This is a docker container that I deploy to other devices not using Azure and want to deploy it using Azure. For the time being - just to get this to work, I don't need to feed any data back to the portal about sensor data. The docker image basically has a web service running on it to communicate to other devices on the local network.
    Monday, January 7, 2019 3:49 PM
  • I basically just want to take an existing Docker image that I have and deploy it to my edge device to run "kind of" stand-alone. Use the Azure IoT Hub to push a Docker image to all of my devices but not necessarily worried at this point about pushing data from the device (this Docker Image) to Azure or from Azure to the device (this Docker image). Is there an easy way to do this with an existing Docker Image instead of using the Tutorial you listed above which creates a new container?
    Tuesday, January 8, 2019 12:35 AM
  • Hi,

    I am not sure if I got it right but your objective would be to deploy new modules on IoTEdge without using Azure for that?

    I believe this can make the trick: https://github.com/Azure/iotedgehubdev

    "

    The Azure IoT EdgeHub Dev Tool provide a local development experience with a simulator for creating, developing, testing, running, and debugging Azure IoT Edge modules and solutions.

    • The bits/code of Edge module running on simulator and IoT Edge Runtime are same.
    • The Edge solution could be run with the simulator locally without pushing image and creating IoT Edge deployment.
    • The credential needed to run Edge solution on simulator is IoT Edge Device Connectionstring. And IoT Hub Connectionstring is not needed.
    • It helps to debug the module on the host (not in container) with the EdgeHub

    "

    Thanks.


    Thursday, January 10, 2019 3:04 PM
    Moderator
  • If I can chime in:

    - From my experience, the Edge Hub only runs when there is a module deployed, eg CSharpModule example.

    - It would be nice if the temperature sensor module could be set up to be built locally. That would give some ideas on how to create a custom module to do same with a real sensor.

    - And some guidance on how to create a local module to get data from a real sensor.


    Embedded MVP

    Sunday, February 3, 2019 4:34 AM
  • Hey,

    Just adding some reference to a sample that uses a "real" temperature sensor :)

    https://azure-samples.github.io/azure-iot-starter-kits/seeed/

    Hope that helps!

    Thanks!

    Tuesday, October 15, 2019 5:01 PM
    Moderator