Page 1 of 1

nginx not resolving floating ip

Posted: Sat Feb 04, 2017 10:37 pm
by bhc
Hi all,

So I got a VPS on digitalocean, added the IP address, I then added a DNS record (subdomain test), updated nginx.conf to have the IP address in, and checked if the site loads. I keep on getting "connection refused".

I checked the IP works, as I can SSH, and access vestacp admin using it, but nginx doesnt want to resolve.

I have also tried setting a user/site to the ip, and had same results. (pushed rebuild to rebuild all config)

I can see nginx is listening to correct IP with netstat -plnt..

I want to use the floating IP as my static IP address, so everything goes through this IP (nameserver/nginx). Apart from mail, as digitalocean doesn't support PTR records. (I guess I have to manually edit the dns records to point mail to the floating ip??).

Re: nginx not resolving floating ip

Posted: Sun Feb 05, 2017 8:16 am
by mehargags
I guess you need to setup NAT IP
pls check this thread:

Why VestaCP use local IP address instead of external IP address...

Re: nginx not resolving floating ip

Posted: Wed Feb 08, 2017 6:03 pm
by bhc
great I got it working.

I had to add the local IP, then NAT that to the floating ip.