You may need to add ‘192.168.55.10’ to ALLOWED_HOSTS.

DisallowedHost at /

Invalid HTTP_HOST header: '192.168.55.10:8000'. You may need to add '192.168.55.10' to ALLOWED_HOSTS.
Request Method: GET
Request URL: http://192.168.55.10:8000/
Django Version: 2.1.8
Exception Type: DisallowedHost
Exception Value:
Invalid HTTP_HOST header: '192.168.55.10:8000'. You may need to add '192.168.55.10' to ALLOWED_HOSTS.
Exception Location: /usr/local/python3/lib/python3.6/site-packages/django/http/request.py in get_host, line 106
Python Executable: /usr/bin/python3
Python Version: 3.6.9
Python Path:
['/www/blog',
 '/usr/local/python3/lib/python36.zip',
 '/usr/local/python3/lib/python3.6',
 '/usr/local/python3/lib/python3.6/lib-dynload',
 '/root/.local/lib/python3.6/site-packages',
 '/usr/local/python3/lib/python3.6/site-packages']
Server time: Monday, 21 October 2019 17:07:12 + 0800

Modify in the project we created setting.py File

ALLOWED_ Hosts = [‘*’], the host requested here is added *

Similar Posts: