Skip to content

Config

SystemConfigData

Bases: BaseSettings

Encapsulates the general configuration of the MMISP Worker application.

Source code in src/mmisp/worker/config.py
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
class SystemConfigData(BaseSettings):
    """
    Encapsulates the general configuration of the MMISP Worker application.
    """

    api_port: PositiveInt = Field(5000, validation_alias="API_PORT")
    """The port exposing the API."""

    api_key: str = Field(validation_alias="API_KEY")
    """The key for the API."""

    api_host: str = Field("0.0.0.0", validation_alias="API_HOST")
    """The host the API binds to."""

    worker_termination_timeout: int = 30
    """The time in seconds to wait for the worker to terminate before kill."""

    worker_api_key: str = Field(validation_alias="WORKER_API_KEY")

api_host = Field('0.0.0.0', validation_alias='API_HOST') class-attribute instance-attribute

The host the API binds to.

api_key = Field(validation_alias='API_KEY') class-attribute instance-attribute

The key for the API.

api_port = Field(5000, validation_alias='API_PORT') class-attribute instance-attribute

The port exposing the API.

worker_termination_timeout = 30 class-attribute instance-attribute

The time in seconds to wait for the worker to terminate before kill.