Refactor Application to use a config file