serve public and error page