Move the configuration code to configuration manager.