Page 1 of 1

Running nginx reverse proxy in front off plesk+asl

Posted: Thu Nov 27, 2014 8:01 pm
by angelos
Hello,

i'm running a seperate server (nginx) as a reverse proxy and when i look on my webserver (plesk+asl) it gives me the ip adres of the nginx server. Not the real ip.
I configured nginx to forward the original ip. Do i have to configure something in asl to make this work.

thank you,

Angelo

Re: Running nginx reverse proxy in front off plesk+asl

Posted: Thu Nov 27, 2014 9:35 pm
by prupert
You can do this with mod_rpaf, an Apache module that gets the real IP from the "X-Forwarded-For" header.

Re: Running nginx reverse proxy in front off plesk+asl

Posted: Fri Nov 28, 2014 8:22 am
by angelos
thx for the repley

i had the module rpaf loaded, but for centos i had to add this config file and reload apache :

/etc/httpd/conf.d/mod_rpaf.conf

RPAFenable On
RPAFsethostname On
RPAFproxy_ips x.x.x.x (replace with the server ip or the originated reverse proxy ip)
RPAFheader X-Forwarded-For


Hope this helps someone else :D