 
     # no cluster specified, but there's only one, so just default to it
     cluster = key for key of config.clusters
-    log "Defaulting to cluster '#{cluster}'\n"
+    log "Defaulting to cluster '#{cluster}'"
 
   target = config.clusters[cluster]
 
   throw new Error "Cluster #{cluster} does not exist in decking.json"  if not target
 
+  if target.group
+    log "Using overrides from group '#{target.group}'\n"
+
   return target
+
+isRunning = (container, callback) ->
+  container.inspect (err, data) ->
+    return callback err if err
+
+    return callback null, data.State.Running


  log "#{padName(name)}  #{message}"

resolveOrder = (config, cluster, callback) ->
  containerDetails = {}

  for containerName in cluster
    container = config.containers[containerName]
    containerDetails[containerName] = container


      if not containerDetails[dependency]
        containerDetails[dependency] = config.containers[dependency]

  # rename any containers based on group stuff, calc some max length stuff
  # merge group overrides if present
  for _, container of containerDetails
    container.originalName = container.name
    if groupName
      container.group = groupName
      container.name += ".#{groupName}"

      # first up, completely replace any container config with
      # the group-wide options
      for key, value of group.options
        container[key] = value

      # now check for container specific overrides...
      if group.containers?[container.originalName]?
        for key, value of group.containers[container.originalName]
          # @TODO we're overwriting here, these should MERGE with
          # those specified group-wide... I think. But only if there
          # was a group wide key maybe?
          container[key] = value

    maxNameLength = container.name.length if container.name.length > maxNameLength

  # resolve dependency order
  depTree = new DepTree
  for _, container of containerDetails
    depTree.add container.originalName, container.dependencies

  list = (containerDetails[item] for item in depTree.resolve())

