Refactor configuration to it's own module