iotedgedev icon indicating copy to clipboard operation
iotedgedev copied to clipboard

[BUG] Simulator not respecting docker status of stopped

Open chull434 opened this issue 3 years ago • 2 comments

Description

Simulator is not respecting docker status of stopped and is creating and starting containers for modules that have status set as stopped "status": "stopped",

"modules": {
  "MyModule": {
    "version": "1.0.0",
    "type": "docker",
    "status": "stopped",
    "restartPolicy": "never",
    "settings": {
      "image": "imagename",
      "createOptions": {}
    }
  }
}

Expected behavior

Simulator start should only create but not start containers for modules that have status set as stopped "status": "stopped",

Actual behavior

Simulator start is creating and starting containers for modules that have status set as stopped "status": "stopped",

Steps to Reproduce

A deployment manifest with a stopped module

"modules": {
  "MyModule": {
    "version": "1.0.0",
    "type": "docker",
    "status": "stopped",
    "restartPolicy": "never",
    "settings": {
      "image": "imagename",
      "createOptions": {}
    }
  }
}

sudo iotedgedev simulator start

Environment

iotedgedev, version 3.3.7 Python 3.7.15 pip 22.3.1 from /usr/local/lib/python3.7/dist-packages/pip (python 3.7) WSL2 Ubuntu 22.04

chull434 avatar Nov 26 '22 19:11 chull434

Thanks for reporting. What is the impacted scenario that caused the module to be stopped?

konichi3 avatar Apr 21 '23 21:04 konichi3

Simply that I want the module to be stopped, disabled, not running. Mainly for development and testing purposes where you just need the module to be stopped with out deleting the entire module from the deployment manifest

chull434 avatar Apr 21 '23 21:04 chull434