Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/quasiyoke/comrade-colonel-bot
Telegram bot removing group chat messages after specified period of time
https://github.com/quasiyoke/comrade-colonel-bot
chatbot privacy telegram
Last synced: 2 months ago
JSON representation
Telegram bot removing group chat messages after specified period of time
- Host: GitHub
- URL: https://github.com/quasiyoke/comrade-colonel-bot
- Owner: quasiyoke
- Created: 2018-07-26T21:03:44.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2020-01-20T12:55:48.000Z (almost 5 years ago)
- Last Synced: 2024-10-15T14:19:57.305Z (3 months ago)
- Topics: chatbot, privacy, telegram
- Language: JavaScript
- Homepage: https://t.me/ComradeColonelBot
- Size: 176 KB
- Stars: 2
- Watchers: 3
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Comrade Colonel Bot
[![Build Status](https://travis-ci.com/quasiyoke/comrade-colonel-bot.svg?branch=master)](https://travis-ci.com/quasiyoke/comrade-colonel-bot)
Telegram bot removing group chat messages after specified period of time.
To try it quickly, run:
```sh
export TELEGRAM_BOT_TOKEN=123456:ABC-DEF1234ghIkl-zyx57W2v1u123ew11
export STORAGE_PATH=/var/lib/comrade-colonel-bot/db.sqlite3
export MESSAGE_LIFETIME=5s
export DELETION_PERIOD=1s
cargo run
```Don't forget to specify your actual Telegram bot token (you're able to get one from `@BotFather`). The bot will be configured to delete all messages he has evidenced after 5 seconds. [Maximal possible](https://core.telegram.org/bots/api#deletemessage) manageable chat message lifetime is 48 hours (172800 seconds).
## Deployment
1. Install [Docker Compose](https://docs.docker.com/compose/install/),
1. Create a file with Telegram bot token to put it into Docker Secrets' store:
```sh
echo -n '123456:ABC-DEF1234ghIkl-zyx57W2v1u123ew11' > ./telegram-bot-token
```1. Fetch bot's deployment configuration file and run the bot:
```sh
wget https://raw.githubusercontent.com/quasiyoke/comrade-colonel-bot/master/docker-compose.yml
docker-compose up
```Default configuration assumes chat messages lifetime of 42 hours.