code: function(cb) {
            docker.listContainers({
              all : 1,
            // filters: '{"status":["running"]}'
            }, function(err, containers) {
              if (err) {
                return cb(err);
              }
  
              var container = null;
  
              for (var c = 0; c < containers.length; c++) {
                if (containers[c].Image.indexOf(utils.qualifiedImageName(tag,
                    options.registry, null)) === 0) {
                  // If the current container is running or terminated
                  if (utils.getContainerStatus(containers[c]) === "RUNNING"
                      || utils.getContainerStatus(containers[c]) === "STOPPED") {
                    container = containers[c];
                    break;
                  }
                }
              }
  
              cb(null, container);
            });
          }
docs: Step 1: search for a running container with the same image