add option to use configuration file.