Question

Telegram Bot Deploying Issue using github

I have telegram bot code which written in python. before digital ocean I use Heroku free version and my bot working fine but when I try to deploy same bot on digital ocean its showing Deploy Error: Health Checks


Submit an answer

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!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

👋 @dropguruji

Great question, I also run a Telegram bot on App Platform (though mine is written in Go) and ran into this same issue.

App Platform expects some sort of service to exist which can be tested against using HTTP or TCP. Though Telegram bots are usually listeners so this healthcheck fails.

My solution was to start a small http server running on port 8080 that returns healthy and some recent stats for my bot. It serves as a healthcheck for App Platform to know my app is still running, and as a way for me to see some information about my bot while running.

Setting up a simple python http/tcp response should resolve this issue.

Hope that helps!