Skip to content
 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

32 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation


HK-Loader & Updater

A Simple Shell Script to make your Repo Deployable to Heroku.com (via CLI) & Auto Update and Fetch your Repo Updates / Commits on Restart with your Repository URL.


Deploy on Heroku

Press the below button to fast deploy to Heroku

Deploy To Heroku

then goto the variables tab for more info on setting up environmental variables.


Heroku CLI Guide

Step 1 : Git clone this Repo and change directory

Make sure git is Installed in your system or quick run apt-get install git pip curl -y

git clone https://github.com/Tamilupdates/HK-Loader && cd HK-Loader

Step 2 : Now Install Heroku in your Sytem or checkout Official Heroku Deploy Docs, or Download via apt-get or npm

For Android : Use termux for CLI usage

curl https://cli-assets.heroku.com/install.sh | sh

Step 3 : Login into Heroku and Log In CLI via Browser

heroku login

Step 4 : Create Heroku App and specify region with App Name

heroku create --region us APP_NAME

Notes:

  • --region eu for Europe Server and --region us for United States Server.
  • APP_NAME should be replaced with your unique app name (Optional). If not given it generates a random name.
  • --stack container for setting stack to container for Dockerfile.
  • --buildpack heroku/python for using build slug for repo deploy and build.

Step 5 : Set Local git remote for Heroku.

heroku git:remote -a APP_NAME

Step 6 : Setup Config Variables for the script to run.

heroku config:set REPO_URL=https://github.com/user/repo REPO_BRANCH=main START_CMD="python -m bot"

Step 7 : Now push to Heroku via git forcefully to build.

git push heroku main -f

All Heroku CLI Commands : Click Here


Mandatory Vars

  • REPO_URL - Deploy Repository URL, Add Private Token if Repo is Private.

    https://github.com/Tamilupdates/FZBypassBot

  • REPO_BRANCH - Repo Branch, you want to deploy with your REPO_URL.

    main

  • START_CMD - Trigger Command for your Bot to Run.

    bash start.sh or python main.py or python -m bot


Important Notes:

  • Repo made for Non-Docker Repos but can be customized for Docker Repos (Read Ahead)
  • If your Repo Uses additional Docker packages or Images, Add Dockerfile (Must Remove Run cmd) here and add heroku.yml file with content as:
    build:
      docker:
        web: Dockerfile
    run:
      web: chmod +x hk_deploy.sh && ./hk_deploy.sh
    • Also Run a extra Command before Deploy or set stack at app creation.
      heroku stack:set container -a APP_NAME
      Available Stacks : container (Dockerfile), heroku-22 (Default), heroku-20 (python-3.8.16 Version Usage) and More
  • Default process type is web, If you use other types like worker.
    • Replace web with worker from heroku.yml and Procfile files.
    build:
      docker:
    --    web: Dockerfile
    ++    worker: Dockerfile
    run:
    --  web: chmod +x hk_deploy.sh && ./hk_deploy.sh
    ++  worker: chmod +x hk_deploy.sh && ./hk_deploy.sh

About

A Simple shell Script to make your Repo Deployable to Heroku.com and Auto Update on Restart.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages