dimanche 26 avril 2015

Deploy multiple Rails applications on a single EC2 server

I have two rails applications on a single EC2 machine at different locations. I would like to have app1.domain1.com to point to one of them while app1.domain1.com to point to another.

I have two records in Route53 to point app1.domain1.com and app2.domain1.com to same IP address and had nginx config route

server {
    listen       80;
    server_name  app1.domain1.com;
    root <path_to_app1>;
    passenger_enabled on;
}
server {
    listen 80;
    server_name app2.domain1.com;
    root <path_to_app2>;
    passenger_enabled on;
}

how ever it appears that even when i try app2.domain1.com it is taking me to app1.




Aucun commentaire:

Enregistrer un commentaire