Tear out more parts of from naemon core to worker

This is simply a continuation from the previous commit

Change-Id: I4a85a475f01f1786ba662eb0709b88d998c31c38
Signed-off-by: Max Sikstrom <msikstrom@op5.com>