0

Okay to start with-
I am building a Telegram bot for scanning my location for covid vaccine availability.
The source code is available here

The program works fine on my PC and I wanted to upload it on a server.
So I found a tutorial online to upload python-based web apps to Heroku to get insight into Heroku. I made the mistake of creating a python environment for a rust app(forgive me, I am just a beginner). Then I fixed it by undoing the changes to the best of my knowledge. Then I learned that Rust requires a buildpack and then I implemented it(hopefully). Then finally I learned of the importance of Procfile and made this (I really hope I didn't get the Procfile wrong).

release: export TELOXIDE_TOKEN=*********
release: export CHANNEL_ID=********
release: export OWNER_ID=*********
release: cargo run

I dint create a "web" process type cuz I think it's only needed when you have a web interface or require Heroku to accept from one.

A Heroku app’s web process type is special: it’s the only process type that can receive external HTTP traffic from Heroku’s routers. If your app includes a web server, you should declare it as your app’s web process.

  • got this from the documentation

Now the problem is that Heroku is showing me this error code while I try to open the app.

Application error An error occurred in the application and your page could not be served. If you are the application owner, check your logs for details. You can do this from the Heroku CLI with the command

I figured this was because I was not using any web interface.

Then I checked the log files and this happened

2021-05-23T13:35:09.287511+00:00 heroku[router]: at=error code=H14 desc="No web processes running" 
method=GET path="/favicon.ico" host=pure-stream-48197.herokuapp.com request_id=8859d568-2f24-4f83- 
b9c8-45e8603a373a fwd="116.68.99.130" dyno= connect= service= status=503 bytes= protocol=https

I tried specifying dyno and also rechecked my "P"rocfile's extension"no extension" I am getting the fundamentals wrong somewhere and not sure what I am doing wrong.
Thank you for helping me out

  • You should probably not include sensitive environment variables in the `Procfile`, but add them as described [here](https://devcenter.heroku.com/articles/config-vars). – Aykut Yilmaz May 23 '21 at 16:07

1 Answers1

0

You need to run a worker: dyno. Please update your Procfile to the following content.

release: export TELOXIDE_TOKEN=*********
release: export CHANNEL_ID=********
release: export OWNER_ID=*********
worker: cargo run
Utkarsh Vishnoi
  • 149
  • 2
  • 14