the error is: “DisallowedHost at / Invalid HTTPHOST header: 'thesis-experiment.com’. You may need to add 'thesis-experiment.com’ to ALLOWEDHOSTS.” i have had the names of my domain in both nginx site-available and my ALLOWED_HOSTS in settings.py but it still does not work.
i followed this tutorial https://digitalocean.com/community/tutorials/how-to-point-to-digitalocean-nameservers-from-common-domain-registrars
and i have put ns1.digitalocean.com, ns2.digitalocean.com and ns3.digitalocean.com in nameservers of godaddy.com but still no luck. please help!
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.
This question was answered by @taheriamirbahador:
I solved the problem by rebooting the server it seems that restarting nginx was not enough; I used the command “sudo reboot” and the “disallowed host” error went away.
I solved the problem by rebooting the server it seems that restarting nginx was not enough; I used the command “sudo reboot” and the “disallowed host” error went away.