By xcrouton
I have a Python Flask service running on my Ubuntu instance. I’m using WSGI and Apache to serve my application. Everything works well as soon as I launch the app and typically a few days afterwards. The problem is, after a few days, my service stops responding. When I ssh back into my instance, I can see python is still running, but the service no longer responds. Trying to curl to localhost results in Connection reset by peer timeout.
The service is still only being hit by a couple of developers, so I would be surprised if the problem is based on load. What can I do to try to diagnose this problem further?
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
If you are using the default Flask web server, Don’t. It’s intended for development only.As an additional resource, it’s worth reading these two blog posts about deploying a Flask application https://notresponding.net/
if you are using the default Flask web server, Don’t. It’s intended for development only. As an additional resource, it’s worth reading these two blog posts about deploying a Flask application https://notresponding.net/
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.