Extension Email Notification


Extension Basics

Title
Email Notification
Name
ckanext-email-notification
Type
Public extension
Description
The **email-notification** extension for CKAN provides a mechanism for sending email notifications
CKAN versions
Download-Url (zip)
Last commit
a year ago (2024-12-16 15:29:43)
Url to repo
Category
Authentication & Security


Background Infos

Description (long)
Show details

ckanext-email-notification

A ckan extension for sending email notifications to system admins.

Included Plugin(s):

email_notification: This plugin sends two types of emails:

Registration Email: e-mail to system admins to inform them about the new user.

Reminder Email: Reminds system admins about users without organization in ckan.

Requirements

Compatibility with core CKAN versions:

CKAN version Compatible?
2.9 Yes
earlier Not Tested |

Installation

To install ckanext-email-notification:

  1. Activate your CKAN virtual environment, for example:

    . /usr/lib/ckan/default/bin/activate
    
  2. Clone the source and install it on the virtualenv

    git clone https://github.com//ckanext-email-notification.git
    cd ckanext-email-notification
    pip install -e .
    pip install -r requirements.txt
    
  3. Add email-notification to the ckan.plugins setting in your CKAN config file (by default the config file is located at /etc/ckan/default/ckan.ini).

  4. Restart CKAN. For example if you’ve deployed CKAN with Nginx on Ubuntu:

    sudo service nginx reload
    

Config settings

Registration Email

This plugin checks the users (obtained via ckan API) creation date in the user table in ckan database and sends e-mail to users who registered in the past 2 minutue.

Therefore, you need to set a job in the system cronjob list to call this plugin every 2 minutues. For instance:

*/2 * * * *  curl -H "Authorization:YOUR_API_KEY" http://localhost:5000/email_notification/user_reg
  • YOUR_API_KEY is the ckan api key which you need to create.
  • replace “http://localhost:5000/” with the target server.

NOTE: If you like to change the 2 minutes time interval, you can change it in “controller/controllers.py”, the variable “TIME_DELTA” (in seconds)

Reminder Email

You can set it on cronjob list to send this email in your desire time in

Version
1.1.0
Version release date
2025-01-23
Contact name
(not set)
Contakt email
(not set)
Contact Url
(not set)


Installation Guide

Configuration hints

To install ckanext-email-notification:

  1. Activate your CKAN virtual environment, for example:

    . /usr/lib/ckan/default/bin/activate
    
  2. Clone the source and install it on the virtualenv

    git clone https://github.com//ckanext-email-notification.git
    cd ckanext-email-notification
    pip install -e .
    pip install -r requirements.txt
    
  3. Add email-notification to the ckan.plugins setting in your CKAN config file (by default the config file is located at

Plugins to configure (ckan.ini)
email_notification
CKAN Settings (ckan.ini)
DB migration to be executed
(not set)
<< back to Extensions