Skip to main content
Version: 5.3

Deploying Scripts for Active Actions

Installation of Smart EDR scripts for active actions of the job scheduler is performed by the utility add_jobscheduler_action_scripts.py. The utility is provided in the smart_edr_ko_maker package, located in the bin directory, and automates the process of generating a ready deployment package.


Installation Sequence

Running the add_task_actions.py Utility

  1. In the smart_edr_ko_maker builder, navigate to the bin directory
  2. Run the utility add_jobscheduler_action_scripts.py
Example execution
python3 add_jobscheduler_action_scripts.py

Installing the Scripts

After executing add_jobscheduler_action_scripts.py, a build directory is created:

  1. smart_edr_jobscheduler_action_scripts.tar.gz - archive containing:
    • executable script (run_edr_task.py)
    • additional files (taskrunner.py, loggermanager.py)
    • configuration file (config.json)
    • Python dependencies
  2. add_jobscheduler_action_scripts.sh - installation script

Transfer the contents of build to all data and master nodes.

Extract the archive smart_edr_jobscheduler_action_scripts.tar.gz using the following commands:

chmod +x add_jobscheduler_action_scripts.sh
./add_jobscheduler_action_scripts.sh
warning

Execute the commands above on all data and master nodes.

Environment Preparation

For the correct operation of Smart EDR scripts for active actions in job scheduler tasks, the following is required:

  1. Install Python 3.10+ on all data and master nodes
  2. Make the installed python interpreter system-wide
info

Starting from version 5.1, Smart Monitor includes Python 3.12, which meets the requirements for executing active actions.

  1. Install libraries required for active actions:
    cd /app/opensearch/utils/scripts/jobscheduler-action
    pip install -r requirements.txt
warning

Perform the above actions on all data and master nodes.

Deployment of Smart EDR scripts for active actions in the job scheduler is complete. Further configuration and creation of tasks with active actions are described in the corresponding article on integration with the job scheduler.