NGINX only for forwarding to LAN
pixel24
nginx-forum at forum.nginx.org
Wed Dec 11 12:42:26 UTC 2019
Hi at all,
first of all a "hello" to the round. I am new here :-)
I want to set up NGINX on my firewall/router (IPFire). But only as reverse
proxy. There are no websites running on the IPFire.
The IP-Fire has a fixed IP on the WAN interface and can be reached from the
Internet.
[IPFire]
WAN: 10.20.30.40
LAN: 192.168.xx.254
Behind the firewall, i.e. in the LAN, there are several web servers each
running on the same port (80) but on different physical servers:
[Server1]
LAN: 192.168.xx.5
[Server2]
LAN: 192.168.xx.6
Furthermore I have an external, official domain (mydomain.de). On the
external root server I have created two subdomains which I redirect to the
IPFire's fixed IP:
gw.mydomain.com -> http://10.20.30.40
cloud.mydomain.com -> http://10.20.30.40
NGINX on the IPfire should now forward all requests directed to
gw.mydomain.de to the server 192.168.xx.5 (and turück)
and requests addressed to cloud.mydomain.com to LAN: 192.168.xx.6
As far as I know the header has to be rewritten so that the remote client
thinks it is communicating with xxxx.mydomain.de and not with 192.168.xx.y.
I tried for hours yesterday to get this with examples from the internet but
nothing worked.
Does this work at all? Can anyone help me?
best regards
pixel24
Posted at Nginx Forum: https://forum.nginx.org/read.php?2,286443,286443#msg-286443
More information about the nginx
mailing list