added support to use config file