[pbs-devel] [PATCH proxmox-backup 00/10] notifications: cleanup in preparation of overridable templates

Maximiliano Sandoval m.sandoval at proxmox.com
Fri Mar 21 13:38:13 CET 2025


Lukas Wagner <l.wagner at proxmox.com> writes:

> When the notification system was brought to PBS, the template strings
> were moved to the template files as they were, without any changes.
> The original templates were an implementation detail which were not
> exposed to the user in any way.
> They were bit inconsistent with regards to how template variables were
> named (e.g. '{{datastore}}', '{{store}}', '{{job.store}}' for
> referring to a datastore), as well es how variables/helpers
> were accessed ({{ var }} vs {{var}}).
>
> With [#6143] on the horizon, notification templates, template variables
> and template helpers become part of our public API and as such
> we should provide some stability guarantees for them.
> As a result, we use this opportunity to do a 'final' cleanup.
>
> The aims of this series are:
>   - cleanup inconsistencies in the existing templates
>   - add custom types which are used to pass template variables
>     to the notification system, serving as documentation of what
>     is passed exactly to each template, as well as protection
>     against accidentally leaking interal code changes into
>     the template rendering process
>
> This series also removes the HTML version of the test notification template.
> In PBS, this was the only template for which we shipped an HTML version.
> This might bee a bit confusing for users writing their own templates,
> hence it is removed. If we ever add HTML templates for the other notification
> types we can add it back.
>
> [#6143] https://bugzilla.proxmox.com/show_bug.cgi?id=6143

I went through this patch series and it looks good to me.

Reviewed-by: Maximiliano Sandoval <m.sandoval at proxmox.com>




More information about the pbs-devel mailing list