- Examples
- Info
- System recommendations
- The Installation / Update process
- Uninstall the Bot
- Usage
- Troubleshooting Guide
- Support my work
This bot is NOT meant to be used in groups.
- CheckMK Version 2.1.p25 or higher
- The programs python3, pip3, git, runuser & sed installed on the server
- Install the bot.
Replace the variables in <> with your respective information.
- omd_site_name (Your OMD Check_MK site which you want to monitor)
- api_token (You get this token from the BotFather of Telegram)
- bot_password (This can be a password of your choice, which will be used later to authenticate to the bot)
wget https://raw.githubusercontent.com/deexno/checkmk-telegram-plus/main/install.sh
bash install.sh <omd_site_name> <api_token> <bot_password>
- Create a rule that exports the notifications using our new Notification Plugin.
To update the bot, simply download the install.sh file again as mentioned above and run it with the 3 required arguments
- Stop the bot
omd_site_name=<omd_site_name>
systemctl stop checkmk-telegram-plus-$omd_site_name
rm /etc/systemd/system/checkmk-telegram-plus-$omd_site_name.service
systemctl daemon-reload
-
Delete all notification rules you have created regarding this bot (as described in step 2 of the installation).
-
Clean and remove all data concerning the bot
rm -Rf /omd/sites/$omd_site_name/local/share/check_mk/notifications/telegram_plus_notify_listener
rm -Rf /omd/sites/$omd_site_name/local/share/checkmk-telegram-plus
By default, the bot doesn't allow any communication until you authenticate with the previously set password in the configuration file. Here's an example:
Retrieving data manually is easy. After authentication, you should see a new icon next to the keyboard – the menu button. Open the menu and select an option. The bot will ask for necessary info and provide results (as seen in the examples).
You can enable or disable messages through the bot. "Loud" and "silent" notifications can also be toggled independently. Note that this setting is ONLY FOR YOU, and all other users will still receive their notifications as normal. And they are decativated by default! So don't forget to activate them!
If you only want to activate the admin settings ONLY for certain users, follow these steps:
- Open the config file of the bot
omd_site_name=<omd_site_name>
nano /omd/sites/$omd_site_name/local/share/checkmk-telegram-plus/config.ini
- If the option ‘admin_users’ does not yet exist in the config file, create it under the [telegram_bot] tab:
[telegram_bot]
...
allowed_users = XXX
admin_users =
notifications_loud = XXX
...
- Whitelist all users for whom you want to activate the admin option by listing their user ID under admin_users. You will find the ID of the respective users under allowed_users once they have verified themselves at the Telegram bot
# Example Config
[telegram_bot]
...
allowed_users = deexno (987654321),adminuser2 (123456789),ViewUser0 (000000000),
admin_users = deexno (987654321),adminuser2 (123456789),
notifications_loud = XXX
- Restart the Bot
systemctl restart checkmk-telegram-plus-$omd_site_name.service