This question already has an answer here:
I am experiencing
502 Bad Gateway errors after deploying a python flask application using dokku on digital ocean. I followed this tutorial to deploy my app on digital ocean using dokku.
2018/10/23 07:40:59 [error] 28652#28652: *1 connect() failed (111: Connection refused) while connecting to upstream, client: xxx.xxx.xxx.xx, server: api.domain.com, request: "GET / HTTP/1.1", upstream: "http://172.17.0.3:5000/", host: "api.domain.com"
Here is proof that the app is up and listening for requests:
2018-10-23T07:37:30.165794640Z app[web.1]: [2018-10-23 07:37:30 +0000]  [INFO] Listening at: http://127.0.0.1:8000 (9)
My question is how configure
proxy_pass in a python flask dokku application.