This is the third and last part of our series on FlexGet. In this part, we will configure the FlexGet email plugin to get email notifications when new content (e.g. new TV Show episode) is available.

In this tutorial, we will use the configuration file that we have already created in the part II of the series.


The configuration file config.yml should look something like this:

tasks:
my task:
rss: https://www.example.com/rss
series:
- Pioneer One:
# You can specify the desired quality using the quality option
# Delete the following line if you want to grab the best quality
quality: 480p
- Deadside:
quality: 720p
transmission:
host: localhost
port: 9091
# The user and password must match the ones set in the GTK+ interface
username: someuser
password: somepassword

Basically, this configuration file allows FlexGet to periodically grab the specified content (i.e. new episodes of Deadside and Pioneer One) from the RSS feed. When FlexGet detects new content (i.e. new RSS entries), it will automatically download it through Transmission.

In this example, we will edit the aforementioned code to enable the email plugin for FlexGet. To use the email plugin, you need a working email account (Gmail or Yahoo).

Gmail Configuration:

  email:
from: from@gmail.com
to: to@gmail.com
smtp_host: smtp.gmail.com
smtp_port: 587
# Replace USER/PASSWORD with your Gmail username & password respectively
smtp_username: USER
smtp_password: PASSWORD
smtp_tls: yes
smtp_ssl: yes

Yahoo Configuration:

  email:
from: from@yahoo.com
to: to@yahoo.com
smtp_host: smtp.mail.yahoo.com
smtp_port: 465
# Replace USER/PASSWORD with your Yahoo username & password respectively
smtp_username: USER
smtp_password: PASSWORD
smtp_tls: yes
smtp_ssl: yes

Final Configuration File:

If we add the email settings to the configuration file, the final result would look something like this:

tasks:
my task:
rss: https://www.example.com/rss
series:
- Pioneer One:
# You can specify the desired quality using the quality option
# Delete the following line if you want to grab the best quality
quality: 480p
- Deadside:
quality: 720p
transmission:
host: localhost
port: 9091
username: someuser
password: somepassword
email:
from: from@yahoo.com
to: to@yahoo.com
smtp_host: smtp.mail.yahoo.com
smtp_port: 465
smtp_username: USER
smtp_password: PASSWORD
smtp_tls: yes
smtp_ssl: yes

This configuration will allow FlexGet to send you email notifications each time new content is made available:


Bonus:

You can schedule your dowloads by adding FlexGet to your crontab list:

export EDITOR=nano
crontab -e

For example, to make FlexGet run in the background once a week, simply add the following line to your crontab list:

@weekly /usr/local/bin/flexget --cron

Various schedule options are available. To use them, simply replace @weekly with one of the following options:

string         meaning
------ -------
@reboot Run once, at startup.
@yearly Run once a year.
@annually (same as @yearly).
@monthly Run once a month.
@weekly Run once a week.
@daily Run once a day.
@midnight (same as @daily).
@hourly Run once an hour.

For more information about crontab, visit this page.

Comments