Reverse Proxy only if physical path not found
Tj Vanderpoel
14 April 2014, 21:56
We currently deploy all of our applications behind Lighttpd2 or Nginx, with the same methodology. Both of these support
forwarding to a reverse proxy if the physical-path is not found by the web server. This removes the need to decide (based on a pattern or extension or ...)
which locations to forward to the proxy. I read the configuration forums and manual pages and it seems Hiawatha's only reverse-proxy option is to
set a regular expression pattern for when to reverse-proxy. Did I miss something or is this the only way to implement it?
Hiawatha version: 9.4
Operating System: Ubuntu 12.04
Hugo Leisink
14 April 2014, 22:51
No, at this moment Hiawatha can only forward to a reverse proxy based on a regular expression.
Tj Vanderpoel
14 April 2014, 23:18
Thanks for the quick response, Hugo. Is this a future feature on the roadmap? We'd really like to give hiawatha a spin but with as many apps as we have depending on this feature it's somewhat of a blocker.
Hugo Leisink
14 April 2014, 23:34
Not sure yet. What kind of website design goes behind the 'forward all non-existing files to a reverse proxy' idea?
Tj Vanderpoel
15 April 2014, 00:56
It's standard in all of our application stacks, mostly ruby, but some java as well. We like the webserver to serve all static assets and only forward to the app servers if there isn't an existing static asset. In these cases we set the webserver's root to something like /path/to/application/public/ and any existing file there gets served by the webserver directly. Any request for which there is not a matching file in that path gets served by the proxied backend.
Hugo Leisink
15 April 2014, 09:54
Ok. I'll take a look at it for the 9.6 release.
This topic has been closed.