error handling (setting http response code)
only configure port