Moved configuration logic into its own file.