Email reporter - installation¶
The Email reporter basically consists of several modules:
- Plugin: CortexEngine plugin for configuring reports
- Scheduler: Python module for sending configured reports by email
Plugin¶
License required!
The desired CortexEngine instance must have a license with the permission UniplexEmailReporter!
Uniplex plugin required!
This plugin can only be used in the context of the Uniplex plugin!
Tip: In the Starter edition and the User group edition, the Uniplex plugin is already pre-installed.
Remote admin¶
Plugin¶
This plugin is installed as usual using the Remote admin.
This is how it works: install plugin
Users¶
The plugin must also be activated for all desired users.
Required permission: UniplexEmailReporter
This is how it works: set user rights
Uniplex¶
Plugin template¶
After installation in the CortexEngine, the plugin must be activated in the Uniplex
- in one (or more) plugin templates and
- such a plugin template must be assigned to the desired users in the user administration.
must be assigned.
This is how it works: activate in plugin template
-
open the Plugin templates
The button Add is used to configure new entries and the button Edit is used to configure existing entries.
-
select the desired template and activate the E-Mail Reporter plugin
In the dialog header, a template can be created with the button Add and another template can be selected with the button Load template . The template will be removed with the button Delete template .
Parameters Meaning Note name meaningful name of the plugin template available plug-in buttons plugins available in the CortexEngine activate with activated plug-in buttons plugins that should be visible for users with this plugin template remove with
change order with and
Field and record type definitions¶
To be able to manage report configurations in Uniplex, its fields and record types are required.
- download and unzip the file
- import the field definitions (in file
!FId.json
) - import the record type definitions (in file
#Dst.ctxexp
)
Perform import separately
Fields and record types must be imported separately!
This is how it works: importing field and record definitions
The import function is located at the bottom left in the system settings.
It opens the dialog Import configurations.
Scheduler¶
Python Version 3.11
The Scheduler module requires Python version 3.11 or higher!
The Scheduler is a Python-based module that realizes the sending of email reports.
It runs outside the CortexEngine at system level and can either be started manually on demand or regularly via CronJob.
Tip: Add $PATH
To simplify use, it is recommended to add the module to the system path:
- find installation location
- include in $PATH (e.g.
.zshrc
or.bashrc
)
Configuration¶
The configuration is carried out via emlrep.ini
, which is divided into the following categories.
Dataservice¶
To be able to read the reports for delivery, the scheduler requires access to the CortexEngine data inventory.
This access takes place via the Uniplex interface:
[DATASERVICE]
no_rec_found=Keine Datensaetze gefunden.
link=localhost:8888/Uniplex/updjsr.php
user=admin
password=admin
Parameters | Description |
---|---|
no_rec_found | requested response if no reports were found |
link | URL of the updjsr.php in a running Uniplex instance |
user | login user name of the linked Uniplex instance |
password | login password of the linked Uniplex instance |
Mailserver¶
A mail server is required for sending emails:
[MAILSRV]
hostname=mailserver.cortex-ag.com
user=cron-mailer@cortex-ag.com
passwd=password
from=Emailreport <no-reply@cortex-ag.com>
ssl=0
port=587
Parameters | Description |
---|---|
hostname | URL of the mail server |
user | login user name for mail server |
passwd | login password for mail server |
from | desired sender address |
ssl | Should SSL be used for the connection to the mail server? (0 = No, 1 = Yes) |
port | access port for mail server |
Administrator¶
Parameters | Description |
---|---|
error_emails | recipient address for administrative/debug emails |
debug | Should emails be sent to the error_emails recipients and not to the recipients defined in the reports? ('False' = No, 'True' = Yes) |
cron_interval | How often should the scheduler be executed? ('day' = 1x daily, 'hour' = 1x per hour) (*1) |
*1: Hour input in the plugin
If cron_interval = day
- i.e. delivery 1x per day - is configured, the hourly input is hidden in the plugin UI.
Configuration - web server¶
The web server that serves the desired instance of the CortexEngine requires the path to the emlrep.ini
file.
This is communicated to the web server in its httpd.ini
file: