i have deployed my code on digital occean hosting. got IP and added ip in A record of my domain in godaddy. now my site works well and hosting pointed to my jaraware.com successfully. but there one strange thing happen that another strange domain also opening my full website. whatever i change in my code its reflects on my domain as well on that strange domain. i dont know why this happpening. my full website opening on one strange domain.

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

×
1 answer

Hi there @parmarjatin834,

It is possible that the other domain name is also pointing to your server’s IP address.

To check that you could use the following DNS lookup tool:

https://www.digitalocean.com/community/tools/dns

If the A record of the strange domain name matches your website, what you could do is add a separate virtual host for your domain name and then create a default virtual host to catch all other traffic and not show your website.

Here is a tutorial on how to add a virtual host to your Nginx webserver:

https://www.digitalocean.com/community/tutorials/how-to-set-up-nginx-server-blocks-virtual-hosts-on-ubuntu-16-04

Regards,
Bobby

by Justin Ellingwood
When using the Nginx web server, server blocks (similar to the virtual hosts in Apache) can be used to encapsulate configuration details and host more than one domain off of a single server. In this guide, we'll discuss how to configure server blocks in Nginx on an Ubuntu...
Submit an Answer