I did some searching and could find what I was looking for. Hopefully you guys can help me.
I have 4 servers. 2 in the US, 1 in Canada, and one in Europe.
I would like to have all the initial incoming traffic hit my one server in Canada first. It has the GeoIP databases installed.
I would like to have the two servers in the US be a 'pool' and have all the requests forwarded to them unless there is a country code exception which would then get forwarded to the server in Europe.
.ANY TRAFFIC -> .CA server -> US SERVER POOL
.SE TRAFFIC -> .CA Server -> European Server
I'd be grateful for any help with the nginx configuration file to accomplish this.
Thanks