Telegram bot that checks if a website is reachable from your Raspberry Pi (thus, from Hungary if your Pi is on a Hungarian ISP). Designed to run in Portainer via Docker.
Default language: Hungarian. Users can switch per chat to English.
- Commands in private or group chats
- Group chats: the bot replies directly in the chat by mentioning the requesting user and replying to their message.
/check <domain|url>— checks reachability from the Pi (DNS + HTTP(S)). If missing/invalid argument, it returns usage./lang <hu|en>— sets the chat language (default: hu)/help— lists all commands
- Uses long polling; no inbound ports required
- Config via environment variables in a
.envfile
- Raspberry Pi with Docker and Portainer (ARM compatible)
- Telegram bot token (from @BotFather)
-
Clone this repository and enter the directory.
-
Create your
.envfrom the example and fill in your bot token:
cp .env.example .env
# edit .env and set TELEGRAM_BOT_TOKEN- Build and run via Docker Compose (Portainer is also supported):
docker compose up -d --build
# nézd a logokat
docker compose logs -f hucheckbot
# ha kell bőbeszédű log
export DEBUG=1 && docker compose up -d --buildPortainer: Add Stack, illeszd be a docker-compose.yml tartalmat, add meg az .env-et. A részletes logoláshoz állíts be egy környezeti változót: DEBUG=1.
src/— TypeScript/Node.js bot (frontend friendly)src/locales/hu.ts,src/locales/en.ts— nyelvi fájlok
docker-compose.yml— convenient stack definition.env.example— template for env vars
TELEGRAM_BOT_TOKEN— requiredDEFAULT_LANG— optional,huoren(default:hu)
- Language preference is stored in memory per chat. If you want persistence across restarts, mount a small volume and implement simple JSON/SQLite storage. The current implementation keeps it simple.
- The bot verifies reachability using DNS resolution and HTTP(S) HEAD/GET from the Pi, which reflects your local ISP routing in Hungary.
- In a group chat, just type
/check google.hu. The bot will reply to your message and mention you. /check google.hu/check https://google.hu- If you omit the target:
/check→ the bot returns usage instructions. /lang en/lang hu
MIT