This may be a stupid question, but after googling a while I can't find the answer or just don't know how to ask it.
I have a web app running on a server named 'myserver1'. I've brought up 'myserver2' with an identical instance of the web app, and set up replication between the two databases on the two boxes. Now, I'd like to employ nginx to do some load balancing, plus make one server take over if the other keels over.
Most of the nginx documentation is written around a simple scenario like this, but it seems to indicate that you put an nginx server in front of the web servers. That would seem to be another single point of failure. How do you make nginx itself redundant? Can you just run nginx on both web server boxes? If so, where do you point the DNS entry of myapp.mydomain.com?
EDIT: I guess I should add that this is for an internal app with a relatively small user base. My primary concern is that our internal users can still get to it if we lose a server or connectivity to one of the data centers. I just can't see how to do that on nginx without introducing another single point of failure.