Methods

Class/Module Index [+]

Quicksearch

Backup::Notifier::Mail

Attributes

address[RW]

SMTP Server Address

authentication[RW]

Authentication type

Acceptable values: :plain, :login, :cram_md5

delivery_method[RW]

Mail delivery method to be used by the Mail gem.

Supported methods:

:smtp - ::Mail::SMTP (default)

Settings used by this method: {address}, {port}, {domain}, {user_name}, {password}, {authentication}, {encryption}, {openssl_verify_mode}

:sendmail - ::Mail::Sendmail

Settings used by this method: {sendmail_args}

:exim - ::Mail::Exim

Settings used by this method: {exim_args}

:file - ::Mail::FileDelivery

Settings used by this method: {mail_folder}

domain[RW]

Your domain (if applicable)

encryption[RW]

Set the method of encryption to be used for the SMTP connection.

:none (default)

No encryption will be used.

:starttls

Use STARTTLS to upgrade the connection to a SSL/TLS connection.

:tls or :ssl

Use a SSL/TLS connection.

exim_args[RW]

Optional arguments to pass to `exim`

Note that this will override the defaults set by the Mail gem (currently: ‘-i -t’) So, if set here, be sure to set all the arguments you require.

Example: ‘-i -t -X/tmp/traffic.log’

from[RW]

Sender Email Address

mail_folder[RW]

Folder where mail will be kept when using the `:file` `delivery_method`.

Default location is ‘$HOME/Backup/emails’

openssl_verify_mode[RW]

OpenSSL Verify Mode

Valid modes: :none, :peer, :client_once, :fail_if_no_peer_cert See +OpenSSL::SSL+ for details.

Use :none for a self-signed and/or wildcard certificate

password[RW]

SMTP Server Password (sender email’s credentials)

port[RW]

SMTP Server Port

send_log_on[RW]

Array of statuses for which the log file should be attached.

Available statuses are: `:success`, `:warning` and `:failure`. Default: [:warning, :failure]

sendmail_args[RW]

Optional arguments to pass to `sendmail`

Note that this will override the defaults set by the Mail gem (currently: ‘-i’). So, if set here, be sure to set all the arguments you require.

Example: ‘-i -X/tmp/traffic.log’

to[RW]

Receiver Email Address

user_name[RW]

SMTP Server Username (sender email’s credentials)

Public Class Methods

new(model, &block) click to toggle source
# File lib/backup/notifier/mail.rb, line 120
def initialize(model, &block)
  super
  instance_eval(&block) if block_given?

  @send_log_on ||= [:warning, :failure]
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.