I have two Rails applications, and I want to host them with only one domain name:
app1.example.com app2.example.com
I have VPS on the digital ocean, and I have already run one application with Nginx and Unicorn. This is my nginx config file:
upstream app1{ server unix:/tmp/unicorn.app1.sock fail_timeout=0; }
I seem to need another server block to host another application, but I don't know how to let nginx distinguish between two server blocks, since I only have one domain. Any ideas?
source share