Hello,
As far as I can tell, the maximum length of each line in the body of an email alert is currently hard-coded to 76. I would like to request a configuration knob for changing it. Based on some testing that I have done, it appears that the following line in the “send” function of LibreNMS/Util/Mail.php is what controls the maximum line length:
$mail->WordWrap = 76:
I propose changing it to:
$mail->WordWrap = LibrenmsConfig::get(‘email_max_line_length’);
The default value of ‘email_max_line_length’ (or whatever is the appropriate parameter name) could still be 76, and it could be limited to 998 to comply with RFC 5322. I’m not even asking that the parameter be configurable via the UI (although that would be handy). Being able to configure it via lnms would be sufficient.
There’s much that we like about LibreNMS. But the device-centric alerting paradigm just doesn’t work well for us. I’ve been trying to get around it with some creative email scripting, but having the lines wrap after 76 characters is making that difficult. Being able to make the lines longer would be very helpful.
Thank you.