   overallState = stateF doc, allServices
   overallState = 'failing' unless overallState
   Instances.update doc._id, $set: state: overallState
-  console.log 'determineState::update'
 
 f = false
 

      status: 'Created'

Instances.find({state: 'removed', desiredState: 'stopped'}, fields: {_id: 1}).observe
  added: (doc, olddoc) -> console.log 'Instance.remove'; Instances.remove doc._id

Instances.find({desiredState: 'running'}, fields: {services: 1}).observe
  changed: (doc, oldDoc) -> determineState doc, runningIsDesired

        updateDoc["services.#{service}.properties"] = properties
        updateDoc.status = "Starting #{service}" if mappedState is 'starting'
        updateDoc.status = "Stopping #{service}" if mappedState is 'stopping'
        Instances.upsert {name: name}, $set: updateDoc
      else
        updateDoc = name: name
