Skip to content

PDF reports

Status reports and SLA summaries as PDF — auto-generated, auto-sent.

What for

  • Monthly SLA report to customer
  • Weekly status to internal management
  • Quarterly audit report for compliance

Manual generation works, the value is in automation.

Report templates

Three built-in templates:

Template Content
SLA monthly Availability per service, incidents, downtimes
Status summary Current state, open problems, trend vs. previous period
Audit report Audit log excerpts with filters, formatted

Custom templates for Pro/Enterprise: upload an HTML+CSS file, rendered by the PDF renderer (WeasyPrint).

Scheduled reports

/reports/scheduledNew:

Field Meaning
Name „Acme SLA April"
Template from list
Scope tenant / tag / hosts
Frequency daily / weekly / monthly
Time cron-like
Recipients list of email addresses
Format PDF (default) or HTML email
Language DE / EN

Example:

name: "Acme Monthly SLA"
template: sla_monthly
scope:
  tenant: Acme GmbH
schedule:
  cron: "0 6 1 * *"   # first day of month at 06:00
period: last_month
recipients:
  - acme-ops@example.com
  - acme-management@example.com
language: en

Manual generation

Ad-hoc:

/reports → Generate report with same parameters, immediate generation. PDF is downloadable + optionally emailed.

Render pipeline

flowchart LR
    SCHED[Scheduler] --> Q[Queue]
    Q --> RENDER[Render job]
    RENDER --> DATA[Fetch data]
    DATA --> HTML[Render HTML]
    HTML --> PDF[PDF via WeasyPrint]
    PDF --> STORE[in object storage / volume]
    PDF --> MAIL[Email with attachment]

WeasyPrint needs no headless browser engine — pure Python lib on Pango/Cairo. Fast, deterministic, with bundled fonts.

Branding

Per tenant you can:

  • Logo (top left)
  • Primary color (header / section heading)
  • Footer text
  • Language (DE / EN)

Set under Admin → Tenants → Branding.

Storage

Generated PDFs land under /opt/vesana/reports/ and are kept 90 days. Browse and download via /reports.

S3 bucket binding via config — PDFs land there instead of locally.

Email distribution

PDF as attachment, body as HTML with short summary („Availability 99.8 %, 4 incidents, …") and link to online view.

When the PDF would be > 25 MB (large tenant), a download link is sent instead — recipient pulls the PDF from Vesana without huge mail.

Custom templates

Pro/Enterprise: upload an HTML file with Jinja2 variables.

{# title.html.j2 #}
<!DOCTYPE html>
<html>
<head>
  <style>{% include "branding.css" %}</style>
</head>
<body>
  <h1>SLA report — {{ scope.tenant.name }}</h1>
  <p>Period: {{ period.from }} to {{ period.to }}</p>
  ...
</body>
</html>

Available variables: scope, period, summary, incidents, downtimes, services, etc.

Export without email

/reports/manual → Generate without sending. Useful for samples or one-off reports.

Permission

Permission Effect
report.view View reports
report.create Manual generation
report.schedule Scheduled reports
report.template_upload Custom templates

Next