nginx proxy hidind ip of vps backend

August 17, 2014 1.2k views

can someone help me with one configuration. I want to setup 2 vps. On will run my site and one will act like a proxy (not load balansing). That proxy need to hide entirely the IP of the backend. Also I want that backend to communicate ONLY with that proxy on specific port. And also need to make that no one can't access that backend, even he/she know the IP of it. So the setup need to look like this:
User -> Internet -> Proxy <--> Backend.
And it is possible to make some kind of tunneling between proxy and backend or something like this?

2 Answers

This should help you out with proxying with NGINX
A more detailed look can be found here

As for only allowing the proxy server to access the backend, your standard operating system firewall (iptables, ufw) should be able to do that for you.

Yea I am aware with this method, but I was wondering if it is possible that someone to know with what server my proxy commucinate and prevent this... I thinking that tunneling Proxy and Backend (to communicate more secure)...Sorry if my explanation is poor...
Simply want I need is ot make proxy hit backend on ssl or some kind secure tunnel not directly on HTTP, need the most secure way as possible

Have another answer? Share your knowledge.