0

This question has a great explanation of a reverse proxy, but if all requests go though a single server in front of a CDN, doesn't this defeat the purpose of having many CDN locations?

For context, I have a completely static website on a CDN but need to separate mobile traffic by user agent and handle those requests with a another server.

Edit: the site is hosted on Netlify, which I believe uses Cloudfront

Will routing all requests through a reverse proxy affect performance?

patmood
  • 1,565
  • 1
  • 12
  • 15
  • Which CDN and what kind of technology it employs is relevant to this question. The reverse proxy *in front of* the CDN would of course almost completely defeat the purpose of the CDN, which is why you'd put it *behind* the CDN... in fact, you could even distribute multiple reverse proxies geographically... depending on the CDN. Please provide more detail on your scenario, present and future. – Michael - sqlbot Sep 29 '16 at 14:12

1 Answers1

3

Yes, using a reverse proxy in a single location in front will defeat the purpose of using a CDN.

Your best bet is to use your reverse proxy as your origin in cloudfront and forward the appropriate application headers then use your reverse proxy to decide what page to render based on those headers

Robo
  • 992
  • 4
  • 10