Send mails with yaml
Project description
Spool allows you to generate test mails specified in YAML.
Installation
pip install .
Usage
spool --help
Example configuration file:
---
# mails.yml
# Optional defaults for keys mails
defaults:
sender: foo@example.com
recipents: Bar <bar@example.com>, baz@example.com
# Optional variables which can be used below
vars:
message: |
Hello world,
Foo bar baz ...
Kind regards,
Foo
# Mails to generate/send
mails:
- name: Test Mail
description: Hello world test mail
headers:
X-Mailer: Spool Mailer
text_body: '{{ message }}'
Send/generate mail(s):
# Send mails to/trought a relay smtp server
spool --verbose --relay localhost:2525 example/simple.yml
# Send mails directly to remote smtp server
spool --verbose example/simple.yml
# Use Google's dns servers for MX rr lookup
spool --verbose --nameserver 8.8.8.8 example/simple.yml
For further examples visit the documentation.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
spool-0.9.3.tar.gz
(12.1 kB
view hashes)
Built Distribution
spool-0.9.3-py3-none-any.whl
(12.9 kB
view hashes)