I'm trying to deploy a Quart web app on Heroku, but I'm getting the infamous "Error R10 (Boot timeout) -> Web process failed to bind to $PORT within 60 seconds of launch".
My current Procfile: web: hypercorn asgi:app
The file to run my Quart app (asgi.py):
import os
from app.main import app
if __name__ == "__main__":
port = int(os.getenv('PORT', 8000))
app.run(host='0.0.0.0', port=port)
Whether, I specify the port and host in app.run() or not, the app works locally but not remotely.
I have also tried setting up the Procfile as web: hypercorn -b 0.0.0.0$PORT asgi:app
and not specifying the port or host in asgi.py. This breaks the app both locally and remotely.
I feel as though I have exhausted the solutions that worked for everyone else, so any other ideas are greatly appreciated.