You can schedule notebook to be executed in time intervals with
schedule parameter in the YAML config. Please specify the time interval with crontab string. You can check the crontab string in the crontab.guru website.
Example YAML config to execute the notebook on every Monday at 8:00:
--- title: My notebook description: My notebook executed automatically schedule: '0 8 * * 1' ---
crontab string should be in quote
Please remember to use quotes when defining the
You can set the timezone by defining the environment variable
TIME_ZONE. It can be defined in
.env variable. Here is the list of available timezones.
For notebooks that are using
schedule you can set automatic email notifications. It can be defined in the YAML configuration with the
--- title: My notebook description: My notebook executed automatically schedule: '0 8 * * 1' notify: on_success: email@example.com, firstname.lastname@example.org, username1 on_failure: email@example.com, username2 attachment: html, pdf ---
You can decide who will be notified about successful or failure execution. You can define persons as emails or usernames. There in an option to add attachment to the email. The HTML or PDF with executed notebook is added to the email.
You need to setup the email settings to make notification works. It requires quite many parameters but don't be scared. It is easy to setup.
You need to set following environment values:
EMAIL_HOST EMAIL_HOST_USER EMAIL_HOST_PASSWORD EMAIL_PORT DEFAULT_FROM_EMAIL
EMAIL_HOST=smtp.gmail.com EMAIL_HOST_USERfirstname.lastname@example.org EMAIL_HOST_PASSWORD=secret-password EMAIL_PORT=587 DEFAULT_FROM_EMAILemail@example.com