#StackBounty: #python #python-3.x #django #localhost #domain-name How do I access my django app on other devices in my environment usin…

Bounty: 100

I have a django app which I hosted locally on my system, now since other devices are connected and on the same local network as my django app, they too are able to access the website by typing the ipaddress:port of my django app host device.

But I wanted those devices also to access my django app using some domain name, but it’s not working. Here is what I tried.

Edited the hosts file on windows and added

127.0.0.1 anythingyoulike.com 
127.0.0.1 www.anythingyoulike.com
127.0.0.1. blog.anythingyoulike.com 

added our custom domain to the allowed host on our settings.py

ALLOWED_HOSTS = ['www.anythingyoulike.com', 'blog.anythingyoulike.com', 'anythingyoulike.com']

But other devices on my hotspot network are unable to access using these domain names, and only my devices where I hosted my django website is able to access it.

Note : There are Android mobile devices too where I want to access using domain name on my local environment


Get this bounty!!!

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.