Fix logging, move to config