Files
tenant-registry/internal/mail/templates/en_document.published.tmpl
T
Sharang Parnerkar afe62e4795 feat(onprem): mails come from the installation, not from us
On APP_ENV=onprem the registry's mails (new findings, published documents)
no longer carry our company signature, address, register entry, contact
address or legal pages. They say the installation sent them, name the
customer's contact (MAIL_CONTACT) and link the customer's imprint and
privacy notice (LEGAL_IMPRINT_URL, LEGAL_PRIVACY_URL), each only when set.

mail.View gets a Site; the zero value is the cloud, so cloud mails stay as
they were (checked byte for byte against the previous templates) apart from
the spelling "Breakpilot", also in the default sender name. The legal line
moved from every text template into signature.tmpl.

On-prem the registry also refuses to start when MAIL_FROM, PORTAL_URL,
INVITE_REDIRECT_URI or LEGAL_* point at breakpilot.com.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
(cherry picked from commit 6058a94254)
2026-11-20 17:08:48 +01:00

24 lines
1.1 KiB
Cheetah

{{define "subject"}}New document for {{.Tenant}}: {{.D.title}}{{end}}
{{define "button"}}Open the document{{end}}
{{define "footer"}}You receive this email because you may view documents in the {{.Tenant}} workspace.{{end}}
{{define "html"}}<p style="margin:0 0 12px 0;font-size:18px;font-weight:bold;">A new document is ready for you</p>
<p style="margin:0 0 12px 0;">Breakpilot published a document in the <strong>{{.Tenant}}</strong> workspace:</p>
<p style="margin:0 0 4px 0;font-weight:bold;">{{.D.title}}</p>
{{if .D.description}}<p style="margin:0 0 12px 0;color:#414669;">{{.D.description}}</p>{{end}}
<p style="margin:0 0 12px 0;">You find it in the portal under <em>Documents</em>. Every download is recorded in the audit log.</p>{{end}}
{{define "text"}}A new document is ready for you
Breakpilot published a document in the {{.Tenant}} workspace:
{{.D.title}}
{{if .D.description}} {{.D.description}}
{{end}}
You find it in the portal under "Documents":
{{.URL}}
{{template "signature_text" .}}
--
You receive this email because you may view documents in the {{.Tenant}} workspace.
{{template "legal_text" .}}{{end}}