I have a few VPS - same files and NGINX, PHP-FPM and stuff. How would I make it so that when the user goes to pingrglobe.com that they get redirected to the nearest server?
Thanks, Samuel.
I have a few VPS - same files and NGINX, PHP-FPM and stuff. How would I make it so that when the user goes to pingrglobe.com that they get redirected to the nearest server?
Thanks, Samuel.
AnyCast is a transparent way of doing this, as MDMarra suggests, and is pretty hardcore. It's a way of having a single IP address in multiple locations. This is akin to haing a single IP address in multiple worldwide locations and should work with pretty much everything.
Another way is to get a DNS provider that provides geo-based DNS. People from different regions will resolve a different IP address for your domain name. As a price point, DNS Made Easy charge $55/month/domain (not sure how many records per domain you get), so $660/year. This will only work with services that use DNS resolution as a connection step (i.e. going directly to an IP address will still connect you to that region).
Another way of doing it is having your primary domain as a light-weight landing page, that compares the users IP address against a known list (like maxmind) and redirects them to us.example.com or emea.example.com or apac.example.com. This is an extra step and will only work for web browsers, or services that use HTTP and respect a 301 redirect.