added app_config variables, error and 404 templates