[pve-devel] [PATCH v4 many 00/69] fix #4156: introduce new notification system

Thomas Lamprecht t.lamprecht at proxmox.com
Mon Jul 24 11:20:45 CEST 2023

On 20/07/2023 16:31, Lukas Wagner wrote:
> # Overview
> The purpose of this patch series is to overhaul the existing mail
> notification infrastructure in Proxmox VE.
> The series replaces calls to 'sendmail' with calls to a
> new, configurable notification module. The module was designed to
> support multiple notification endpoints, 'sendmail' using the system's
> sendmail command being the first one. As a proof of the extensibility
> of the current approach, the 'gotify' [1] plugin was also implemented.
> The patch series also includes groups. They allow to send a notification
> to multiple endpoints at the same time. Furthermore, there are filters.
> Endpoints and groups can configure filters to determine if a notification
> should be sent. For now, filters can only be configured based on notification
> severity.
> A short summary of what is included in this patch series:
>   - Sendmail endpoint plugin: uses the system's `sendmail` command 
>     to send - well - mail. The sendmail plugin sends multi-part mails
>     containing HTML as well as plain text.
>   - Gotify endpoint plugin: sends a notification to a gotify server
>   - Groups: As for any notification event one is only able to select a single
>     target, groups can be created to notify multiply endpoints at the same time
>   - Filters: Endpoints and groups can also have filtering: The filter 
>     can match on the notification's metadata (only severity for now) to 
>     determine if it will be sent or not. Filters can be easily extended in 
>     the future to match on other structured metadata as well.
>   - REST API for managing endpoints, groups and filters
>   - Overhauled GUI for backup jobs/one-off backups - here the use can now 
>     select a notification target
>   - GUI for configuring the other notification events 
>     (APT, replication, fencing) - here the user can configure *when* and
>     *where* to send a notification
>   - Notification rendering based on templates: 
>     From a single template, the system can render notifications to either
>     plain text or HTML.

While I didn't got around for a thorough review, I did some spot checking
of the code here and liked what I saw, nice work!

The base design seems OK and any implementation bug/detail can be fixed
with follow ups, so fine for me to apply (Wolfgang should start soon doing
so, at least the rust backend and perlmod stuff).

More information about the pve-devel mailing list