Add email delivery for vulnerabilities exports

What does this MR do and why?

This MR adds a notification email when vulnerability exports finish. This facilitates moving exports to an asynchronous workflow.

There are additional changes needed before this feature is complete, which will be handled outside this MR:

  1. Add a cron worker to delete expired exports
  2. Update frontend to indicate that export will be delivered via email instead of polling for status

References

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

  1. Enable feature flags:

    Feature.enable(:asynchronous_vulnerability_export_delivery_for_groups)
    Feature.enable(:asynchronous_vulnerability_export_delivery_for_projects)
  2. Go to http://gdk.local:3000/<project>/-/security/vulnerability_report and click the export button

  3. Open http://gdk.local:3000/rails/letter_opener/ and check for email

HTML email Text email
Screenshot_2025-03-03_at_16.18.01 Screenshot_2025-03-03_at_16.18.11
Edited by Ugo Nnanna Okeadu

Merge request reports

Loading