Cleanup the configuration manager to be more flexible