nginx - keeping default page with other websites on server ip

January 3, 2014 1.5k views
Hello all, Using ubuntu 12.04 + varnish + nginx +apc I have been able to correctly set up multiple websites, but when I try to add default ip page (welcome to nginx), it breaks something, i mean either it takes or others to default page , When i remove it(default server block), everything works except when i open ip it takes me to 1 of my domain. So my question is it compulsory to remove that block? I want my server ip to show nginx default page, primarily to ensure no ip canonicalization, I have added all blocks in single default file so is that symbolic link also required each time for every domain added? (sudo ln -s /etc/nginx/sites-available/wordpress /etc/nginx/sites-enabled/wordpress) because mine are working without adding that link, except the default added already. Also is it better to create different file for every server block or one file is good to go? Thanks
1 Answer
found the problem,
hadn't added server block for www.
Have another answer? Share your knowledge.