adds reading config and bind to config