Thank you for the nice script! For me it is working like a charm.
Sorry for a little offtopic, but after hours of googling I did not find any good answer for my problem. I guess you guys can help me:
I would like to implement this or a similar solution for other debian based systems (root server and a few raspberrys). As far as i know there a at least two possibilities:
1) I know there is a related script (link) and I'm using this too, e.g. for specified notifications. Maybe i could setup such a service in all systems and pipe the normal emails to this script. But I cant find a good solution to replace all my default system notifications like in your script for omv. Do you have an idea how to use your script or the linked onw to replace all emails with telegram?
2) Alternatively, maybe I could install a telegram bot which catches all emails from different systems and forwarding it to a specified telegram id. With this version I could use the normal email MTA on every system and have just to setup one centralized bot. There are ready to use such telegram bots, but I dont want to use stranger services for this.
Even if the second version saves a lot of time and i could use this for literally all email notifications I like the instant messaging from your omv script. So I tend to use the first version.
Thank you in advance and greetings
74m