zuul/doc/source/admin/drivers/smtp.rst

2.0 KiB

title

SMTP Driver

SMTP

The SMTP driver supports reporters only. It is used to send email when items report.

Connection Configuration

<smtp connection>

driver

smtp

The connection must set driver=smtp for SMTP connections.

server

SMTP server hostname or address to use.

port

SMTP server port.

default_from

Who the email should appear to be sent from when emailing the report. This can be overridden by individual pipelines.

default_to

Who the report should be emailed to by default. This can be overridden by individual pipelines.

Reporter Configuration

A simple email reporter is also available.

A connection<connections> that uses the smtp driver must be supplied to the reporter. The connection also may specify a default To or From address.

Each pipeline can overwrite the subject or the to or from address by providing alternatives as arguments to the reporter. For example:

- pipeline:
    name: post-merge
    success:
      outgoing_smtp:
        to: you@example.com
    failure:
      internal_smtp:
        to: you@example.com
        from: alternative@example.com
        subject: Change {change} failed

pipeline.<reporter>.<smtp source>

To report via email, the dictionaries passed to any of the pipeline reporter<reporters> attributes support the following attributes:

to

The SMTP recipient address for the report. Multiple addresses may be specified as one value separated by commas.

from

The SMTP sender address for the report.

subject

The Subject of the report email.