updated agent to read commands from services file