Hi! Can I redirect request from client on the local directory(server) via
haproxy? For example:
If user send request - crossdomain.xm I am redirect its on the directory
/opt/crossdomain/ , folder for files. This is file be on the server whith
haproxy.
In NGINX this is has form
location / {
root /opt/nginx/www/; # folder for store files
index crossdomain.xml;
as I know HAProxy is a reverse proxy and not a webserver with reverse proxy capability. If you want you can configure HAProxy to proxy on filename to your nginx backend.
frontend crossdomain
mode http
bind *:80
..... your config
acl is_xml path_end crossdomain.xml
use_backend nginx_BE if is_xml
backend nginx_BE
mode http
server nginx x.x.x.x:xx
I hope the experts share my opinion and my brain-snippet ist correct! As “always” (with 2 posts) no garantee for a working config… it’s only an hint how it can work!