Moved config stuff to its own library