Home > Enterprise >  Flask Webserver on Amazon Linux 2 - This site can’t be reached on browser
Flask Webserver on Amazon Linux 2 - This site can’t be reached on browser

Time:02-03

I have started a Flask Webserver on an Amazon Linux 2 EC2 instances

(venv) [ec2-user@ip-10-0-1-63 microblog]$ flask run
 * Serving Flask app 'microblog.py'
 * Debug mode: off
WARNING: This is a development server. Do not use it in a production deployment. Use a production WSGI server instead.
 * Running on http://127.0.0.1:5000
Press CTRL C to quit

When i try to access the Web either via the below Public V4 DNS or Public V4 IP i get "Site cannot be reached"

  • enter image description here

    check if 0.0.0.0: in your case, 0.0.0.0:5000 is showing in output or not.

    Then try to run with below command:

    flask run --host=0.0.0.0

    Let me know, if that works. #Cloudkaramchari

  • Related