Sign inSign up

dsoloviev/telegram-git-bot

By dsoloviev

•Updated over 7 years ago

Simple gitlab and github telegram bot

Image
0

920

dsoloviev/telegram-git-bot repository overview

⁠gitlab webhook telegram bot

Simple gitlab telegram bot that listen to gitlab webhooks and send each event to the authenticated chats

https://core.telegram.org/bots⁠

Create a new bot https://core.telegram.org/bots#create-a-new-bot⁠ and then copy the token to the token file.

⁠Requirements

Only work with python3

⁠How to use

  1. Change the authmsg file with some secret keyworld
  2. Run the app.py in your server
  3. Create a webhook in your gitlab project that points to http://yourserver:10111/⁠
  4. Talk to your bot and write only the keyworld
  5. You will receive each event in your repo

⁠FAQ

⁠Q. How can I stop receiving messages

R. Write "shutupbot" in your conversation and the bot won't talk to you anymore

⁠Q. How can I enable the bot in group chats

R. Write /keyworld instead of keyworld

⁠Interesting files

  • chats, the json with all the chats to send notifications
  • token, the bot token
  • offset, the last msg id received from telegram api

⁠Docker pull from repo

⁠Pull image from docker hub

$ docker pull dsoloviev/telegram-git-bot

⁠run

$ docker run -d -p 10111:10111 --name telegram-git-bot -e AUTHMSG="XXX" -e TOKEN="XXX:XXX" dsoloviev/telegram-git-bot

⁠Docker build local image

⁠image build

$ docker build -t bot .

⁠run

$ docker run -d -p 10111:10111 --name bot -e AUTHMSG="XXX" -e TOKEN="XXX:XXX" bot

Tag summary

Content type

Image

Digest

Size

42.1 MB

Last updated

over 7 years ago

docker pull dsoloviev/telegram-git-bot