Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

175
Vistas
Cannot access my Django page hosted on AWS EC2 instance

I cannot access my Django app on an EC2 instance (host2) in my browser by typing its public DNS name with port number: ec2-public-dns-of-this-instance.compute-1.amazonaws.com:8000

  1. I'm using the same Security Group that my other EC2 instance (host1) is using which is working just fine (my other Django app hosted on this instance works perfectly fine), with HTTP/TCP open on 0.0.0.0/0 on port 8000
  2. I started my Django project this way: ./manage.py runserver 0.0.0.0:8000
  3. I've added hosts into my ALLOWED_HOSTS file which has these now: ALLOWED_HOSTS = ['*', '127.0.0.1', 'ec2-public-dns-of-this-instance.compute-1.amazonaws.com', '0.0.0.0', 'localhost']
  4. I was able to curl localhost:8000 which returned me 200 and Django default HTML page when I'm ssh'ed into this instance.
  5. I was able to curl ec2-public-dns-of-this-instance.compute-1.amazonaws.com:8000 which also returned me 200 and Django default HTML page when I'm ssh'ed into this instance.
  6. both host1 and host2 are using the exactly the same subnet, VPC, SG, AMI, in the same AZ.
  7. both host1 and host2 are running on AMI Ubuntu 18.04 LTS

Any ideas how to fix this would be greatly appreciated!

over 4 years ago · Santiago Trujillo
1 Respuestas
Responde la pregunta

0

Interestingly, it started working three hours later. I didn't change anything and all things remain the same as I described above. I have no clue why this is the case...

over 4 years ago · Santiago Trujillo Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda