- Newest
- Most votes
- Most comments
Please ensure the host is added with its port in the ALLOWED_HOSTS
configuration:
ALLOWED_HOSTS = ['13.53.67.74', '127.0.0.1', '13.53.67.74:8000', '127.0.0.1:8000']
NOTE: This is not recommended for production as it's not the standard use and can expose the application to unnecessary risks.
Have you restarted the Django services?
From a terminal, something like the following command
systemctl restart uwsgi.service
Yep., authentical failed despite entering correct credentials. Proves my point. AWS making non-existent issues. So sick of this. Why can't something just bloody do as its told?!
But of course, something just work as it should would simple make my life so much easier, wouldn't it? We can't have that, now, can we? We can't just have something just do as its told. Oh no, I have to scream, I have to shout, I have to cry, I have to absolutely go bat sh*** crazy, don't I? IU have to have my entire day ruined just because I constantly end up using complete garbage SAAS.
Relevant content
- asked a year ago
- AWS OFFICIALUpdated 7 months ago
- AWS OFFICIALUpdated 8 months ago
- AWS OFFICIALUpdated 2 years ago
- AWS OFFICIALUpdated 7 months ago
Noted, however still didn't work (no surprise there). BUT I do see in the Django debug page that under Request Information > Settings it's telling me that it's trying to access ALLOWED_HOSTS = ['127.0.0.1'] DESPITE correctly updating the ALLOWED_HOSTS variable in the settings.py. Its like It has not had another look at this and gone "Oh I see you have updated this, sorry!"
Why? For a seemingly reputable company, which is an absolute disgrace
Could you please share the
ALLOWED_HOSTS
section of yoursettings.py
file to help identify the issue?This is the error
invalid HTTP_HOST header
, isn't this? Which Django version are you using? Do you have thisUSE_X_FORWARDED_HOST
enable in yoursettings.py
?You know, I think I'm developing some sort of psychic ability here. I mean, how did I know that sticking an :8000 after the ALLOWED_HOSTS will yield the same bloody result? It's amazing How I have attained this ability, is it not? These Instances are so thick its almost funny.
Yes, that is the error, I'm using Django 5.0.bloody4 and No I am not using USE_X_FORWARDED_HOST because it should sodding work without it! Why is Django refusing to connect to the correct IP address?
In addition to this, I am just about to seriously lose my temper. If I see that error one more time I am seriously going to start screaming. I am sick to death of this.