[pmg-devel] [PATCH pmg-api v2 0/2] fix #4211: convert quarantine link mail to template

Christoph Heiss c.heiss at proxmox.com
Mon Oct 7 12:32:10 CEST 2024


Fixes #4211 [0] by converting the currently hardcoded text for the
quarantine link mail to a proper template, enabling users to write their
own versions.

This series also adds the possibility to specify both a HTML and
plaintext template for PMG::Utils::finalize_report() (or just HTML, for
backwards compatibility) - as suggested in [1]. 

[0] https://bugzilla.proxmox.com/show_bug.cgi?id=4211
[1] https://lore.proxmox.com/pmg-devel/20241003172625.49655705@rosa.proxmox.com/

Christoph Heiss (2):
  utils: allow specifying plain and/or html for finalize_report()
  fix #4211: convert quarantine link mail to template

 src/Makefile                           |  2 ++
 src/PMG/API2/Quarantine.pm             | 21 ++++++++++-----------
 src/PMG/Backup.pm                      |  2 +-
 src/PMG/CLI/pmgqm.pm                   |  5 ++++-
 src/PMG/CLI/pmgreport.pm               |  5 ++++-
 src/PMG/Utils.pm                       | 26 +++++++++++++++++++++-----
 src/templates/quarantine-link.html.tt  | 13 +++++++++++++
 src/templates/quarantine-link.plain.tt |  5 +++++
 8 files changed, 60 insertions(+), 19 deletions(-)
 create mode 100644 src/templates/quarantine-link.html.tt
 create mode 100644 src/templates/quarantine-link.plain.tt

-- 
2.46.0





More information about the pmg-devel mailing list