Hosting multiple domains with Nginx in Ubuntu 14.04 on Digital Ocean

So I was having problem with my previous server. Now that I’ve rebuilt everything I’ve realized that the problem I was having could have been easily fixed with my previous install. But, it doesn’t matter; it was time to upgrade from Ubuntu 12.04 to 14.04 anyway. The goal of the server is simple: host two domains using Nginx. The problem I was having with the 12.04 install was that I could never get the second domain to serve up the right files; it would always serve up the first domain. This turned out to be a problem with the Nginx configuration. I thought this was the case at the time, but since the install wasn’t doing anything else anyway, I thought it was a good time to rebuild and start from scratch. ...

July 12, 2014 · 3 min · Justin Langhorst