Respect x-forwarded-* headers based on configuration
Extracted from the implementation used within the Photo API. This is likely to be useful as we have more services deployed behind the API Gateway.
Closes https://gitlab.developers.cam.ac.uk/uis/devops/iam/photo-api/-/issues/12