Skip to content

Bot for creation GitHub issue from Telegram chat (for GitHub organization)

License

Notifications You must be signed in to change notification settings

annndruha/issue-github-telegram-bot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Bot for creation GitHub issue from Telegram chat

version GitHub license python lint

Only for GitHub organizations repos issues (not for personal repos issues)

Example usage:

In organization Telegram chat type /issue and write issue title (and optional description). Select repo and enjoy your issue! image

Setup

  1. You need to create telegram bot via BotFather, get bot token and add it to group chat with access messages rights.

  2. Use your personal GitHub account or create another account, get GitHub token. Token scopes must include: repo (full), admin:org -> read:org, user -> read:user. Add account to your GitHub orgainzation.

  3. [Option 1]: Setup the GitHub runner Enviroment (see deploy.yml):

    secrets:

    • BOT_TOKEN - From step 1
    • BOT_NICKNAME - From step 1 (Must start with @)
    • GH_ACCOUNT_TOKEN - From step 2

    variables:

    • GH_ORGANIZATION_NICKNAME - Organization login (nickname) for manage issue
  4. [Option 2]: Simple Docker run without GitHub runner:

    docker run  --detach \
                --restart always \
                --env BOT_TOKEN='000000:token_value_from_botFather' \
                --env BOT_NICKNAME='@nickname_from_botFather' \
                --env GH_ACCOUNT_TOKEN='github_user_token' \
                --env GH_ORGANIZATION_NICKNAME='org_login' \
                ghcr.io/annndruha/issue-github-telegram-bot:latest
    
  5. (Optional, but recommended):

    • Via BotFather go to Edit bot/Edit commands and set this commands:
      start - Hello message
      help - Usage instruction
      md_guide - Markdown syntax instruction
      
    • After this in personal messages with bot you will see a menu button