##################### Self-orchestrator ##################### .. contents:: :local: :depth: 1 Introduction ============ The aerOS self-orchestrator module is one of the 4 essential modules within the aerOS self-* capabilities set. Composed by a rules engine, a facts generator, a trigger and wrapped by an API, it is capable of managing facts, rules and alerts, obtaining information from the self-awareness, self-realtimeness, self-diagnose and self-optimisation and adaptation modules to send warnings about problems in the IE to the aerOS orchestration systems, with the goal to improve the management and coordination of their own workloads. This improves the scalability of tasks and reduces the number of errors that occur during task execution. Features ======== Place in architecture ===================== The following figure describe the self-orchestrator module inside the IE and the relationships with another self-* modules. .. image:: ./self_capabilities_relationships.png :alt: self-orchestrator module inside the IE and the relationships with another self-* modules :align: center User guide ========== To start using the self-orchestrator module, please visit the `Common deployments `_ repository for more information. .. warning:: Remember to manually create *facts* and *rules* folders if you run the image in Docker. In Kubernetes they are created automatically: - *facts*: */etc/aeros/self-orchestrator/facts* - *rules*: */etc/aeros/self-orchestrator/rules* The Docker image is split according to architecture (AMD64 and ARM64). Therefore, when launching it in Kubernetes or Docker, the deployment files must be modified to select the architecture. Prerequisities ============== Installation ============ To test the code locally: 1. Download `script.py `_ and `script.py `_ files in the same folder. 2. In the same directory where the files were downloaded, run the following command to install the necessary dependencies: .. code-block:: bash npm install 3. In the same directory where the files were downloaded, run the following command to create two folders called *facts* and *rules*: .. code-block:: bash mkdir facts rules 4. In the same directory where the files were downloaded, run the following command to launch the self-orchestrator: .. code-block:: bash node script.js Configuration options ===================== - **AEROS_HLO_URL**: the URL where HLO is running. - **AEROS_IOTA**: indicates whether IOTA is enabled in the Domain or not. - **AEROS_IOTA_URL**: the URL where IOTA is running (IP and port). - **AEROS_IOTA_NODE**: IOTA node to send the message to. - **AEROS_ORION_URL**: the URL where the context broker is running (IP and port). Developer guide =============== Authors ======= Universitat Politècnica de València License ======= Notice (dependencies) =====================