dssg / tyra

Prediction model evaluation
Other
4 stars 1 forks source link

localhost -> 0.0.0.0 #71

Closed nanounanue closed 7 years ago

nanounanue commented 7 years ago

Reason:

The web server running in your container is listening for connections on port 5000 of the loopback network interface (127.0.0.1). As such this web server will only respond to http requests originating from that container itself.

In order for the web server to accept connections originating from outside of the container you need to have it bind to the 0.0.0.0 IP address.

As you are using Flask, this can be easily achieved in your runserver.py file by using:

if __name__ == '__main__':
    app.run(host='0.0.0.0')

....

from https://stackoverflow.com/questions/26423984/unable-to-connect-to-flask-app-on-docker-from-host

codecov-io commented 7 years ago

Codecov Report

Merging #71 into master will not change coverage. The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master      #71   +/-   ##
=======================================
  Coverage   72.22%   72.22%           
=======================================
  Files           4        4           
  Lines         378      378           
=======================================
  Hits          273      273           
  Misses        105      105

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 6b1c817...e1a7d59. Read the comment docs.