Drop official support for heroku
Signed-off-by: lzzy12 <jhashivam2020@gmail.com>
This commit is contained in:
parent
2d1cbe0695
commit
e982c47252
50
README.md
50
README.md
|
|
@ -84,53 +84,3 @@ sudo docker build . -t mirror-bot
|
|||
```
|
||||
sudo docker run mirror-bot
|
||||
```
|
||||
|
||||
## Deploying on Heroku
|
||||
- Run the script to generate token file(token.pickle) for Google Drive:
|
||||
```
|
||||
python3 generate_drive_token.py
|
||||
```
|
||||
- Install [Heroku cli](https://devcenter.heroku.com/articles/heroku-cli)
|
||||
- Login into your heroku account with command:
|
||||
```
|
||||
heroku login
|
||||
```
|
||||
- Create a new heroku app:
|
||||
```
|
||||
heroku create appname
|
||||
```
|
||||
- Select This App in your Heroku-cli:
|
||||
```
|
||||
heroku git:remote -a appname
|
||||
```
|
||||
- Change Dyno Stack to a Docker Container:
|
||||
```
|
||||
heroku stack:set container
|
||||
```
|
||||
- Add Private Credentials and Config Stuff:
|
||||
```
|
||||
git add -f credentials.json token.pickle config.env
|
||||
```
|
||||
- Commit new changes:
|
||||
```
|
||||
git commit -m "Added Creds."
|
||||
```
|
||||
- Push Code to Heroku:
|
||||
```
|
||||
git push heroku master --force
|
||||
```
|
||||
- Restart Worker by these commands:
|
||||
```
|
||||
heroku ps:scale worker=0
|
||||
```
|
||||
```
|
||||
heroku ps:scale worker=1
|
||||
```
|
||||
Heroku-Note: Doing authorizations ( /authorize command ) through telegram wont be permanent as heroku uses ephemeral filesystem. They will be reset on each dyno boot. As a workaround you can:
|
||||
- Make a file authorized_chats.txt and write the user names and chat_id of you want to authorize, each separated by new line
|
||||
- Then force add authorized_chats.txt to git and push it to heroku
|
||||
```
|
||||
git add authorized_chats.txt -f
|
||||
git commit -asm "Added hardcoded authorized_chats.txt"
|
||||
git push heroku heroku:master
|
||||
```
|
||||
|
|
|
|||
|
|
@ -1,5 +0,0 @@
|
|||
build:
|
||||
docker:
|
||||
worker: Dockerfile
|
||||
run:
|
||||
worker: bash start.sh
|
||||
Loading…
Reference in New Issue