Docker. Failed to establish a new connection: [Errno 111] Connection refused' Docker. Failed to establish a new connection: [Errno 111] Connection refused' flask flask

Docker. Failed to establish a new connection: [Errno 111] Connection refused'


  1. app1 is missing the port, you should add it:

    app.run(debug=True, host='0.0.0.0', port=5000)

  2. when calling to app1 from app2 you should use its host instead of 0.0.0.0:

    r = requests.post('http://web:5000/users/', data=data)