Skip to main content
Version: Next

Architecture of Salt.Box

Architecture of the Salt.Box software suite
Figure 1. Architecture of the Salt.Box software suite

Table 1. Interactions between components, containers and subsystems of the Salt.Box software suite
Описание
1User interaction with the web application via the http or https protocol
2The web application works with the API gateway via a reverse proxy
3The user's login and password are transferred to the KeyCloak to perform the authentication procedure
4To store the user's registration data and the hash of their password, KeyCloak uses the PostgreSQL
5Integration of KeyCloak with the corporate LDAP directory allows you to use existing user accounts. Using OpenID Connect provides single sign-on for all connected applications
7KeyCloak issues JSON Web Token (JWT) for web application access to Salt.Box components
8Passing JWT as part of any request made by the web application
9API Gateway validates JWT received as part of any request against the KeyCloak
10If JWT is valid, API Gateway queries OPA (Open Policy Agent) for the token owner's access policy to Salt.Box
11Checking for updates, receiving, packing and saving changes in bundles
12If the access policy allows the user to make the request, API Gateway forwards the request to the core of the Salt.Box
13Service Core stores temporary data (pillars data, jobs, job execution results) in the key-value Redis store
14Salt engines also have access to Redis store, get from it and save Job Returns and other data structures. The results of job execution are saved with a specified time to live (TTL)
15, 16The Core service makes synchronous calls (RPC) and processes events (Events) via a message broker based on Redis Pub/Sub channels, managed by the FastStream framework
17Static data (collections, minion and master server parameters, job schemes, task templates, Salt.Box settings) are stored in a DB managed by MongoDB
18After processing the request and executing the corresponding jobs on the SaltStack minion side, the Core service returns a response to the API gateway
19The API gateway passes the response to the web application to display the result to the user
20The Core service launches long-running asynchronous tasks via Taskiq, using RabbitMQ as a message broker. Additionally, Taskiq provides a scheduler for executing tasks
21The request to the Salt.Box extension module is executed in the same way as in item 12
22The Salt.Box extension module launches long-running asynchronous tasks in the same way as in item 20
23After processing the request and executing the corresponding jobs on the SaltStack minion side, the Salt.Box extension module returns a response to the API gateway
24Salt Master publishes jobs, receives events created by the minion, generates its own events
25The minion receives tasks jobs, receives events created by the master, generates its own events
26Receiving data from the Salt Master's built-in file server
27Data returned by the minion (Job returns)