MetaDefender Core Hub (Hub)
The Hub component supports its own configuration file in JSON format.
{ "log": { "streams": [ { "log_type": string, "log_level": string, "log_path": string } ] }, "input": { "technology": "rest", "config": { "port": integer, "log_path": string, "log_level": string } }, "cache": { "technology": "redis", "config": { "host": string, "port": integer } }, "database": { "technology": "postgres", "config": { "host": string, "port": integer, "user": string, "password": string, "dbname": string } }, "broker": { "technology": "rabbitmq", "config": { "host": string, "port": integer, "user": string, "password": string } }, "storage": { "technology": "h2", "config": { "host": string, "port": integer, "connection_key": string } }}| Key path | Required | Value type | Accepted values | Description |
|---|---|---|---|---|
| log.streams[@].log_type | yes | string |
| Type of log device |
| log.streams[@].log_level | yes | string |
| Level of log message |
| log.streams[@].log_path | yes | string | If If
| Location where logs are written |
| log.streams[@].log_format | no | string | default | Format of written log |
| input.technology | yes | string | rest | Technology of input for Hub to get user requests |
| input.config.port | yes | number | Port where NGINX listens for new requests | |
| input.config.log_path | yes | string | Path for NGINX to write its own log | |
| input.config.log_level | yes | string |
| Level of NGINX own log message |
| cache.technology | yes | string | redis | Technology of caching for Hub to cache data |
| cache.config.host | yes | string | IP address (V4/V6) or host for Hub to connect to caching server | |
| cache.config.port | yes | number | Port for Hub to connect to caching server | |
| database.technology | yes | string | postgres | Technology of database for Hub to query to |
| database.config.host | yes | string | IP address (V4/V6) or host for Hub to connect to database server | |
| database.config.port | yes | number | Port for Hub to connect to database server | |
| database.config.user | yes | string | Username of the user Hub uses to connect to database server | |
| database.config.password | yes | string | Password of the user Hub uses to connect to database server | |
| database.config.dbname | yes | string | metadefender_core | Name of shared database for Hub to connect to |
| broker.technology | yes | string | rabbitmq | Technology of broker for Hub to deliver tasks |
| broker.config.host | yes | string | IP address (V4/V6) or host for Hub to connect to broker server | |
| broker.config.port | yes | number | Port for Hub to connect to broker server | |
| broker.config.user | yes | string | Username of the user Hub uses to connect to broker server | |
| broker.config.password | yes | string | Password of the user Hub uses to connect to broker server | |
| storage.technology | yes | string | h2 | Technology of file storage for Hub to stream file to/from |
| storage.config.host | yes | string | IP address (V4/V6) or host for Hub to connect to file storage server | |
| storage.config.port | yes | number | Port for Hub to connect to file storage server | |
| storage.config.connection_key | yes | string | The same string which is used to set up file storage server |
Example:
{ "log": { "streams": [ { "log_type": "file", "log_level": "info", "log_path": "C:/opswat/log/hub.log" } ] }, "input": { "technology": "rest", "config": { "port": 7778, "log_path": "C:/opswat/log/nginx_log.log", "log_level": "warning" } }, "cache": { "technology": "redis", "config": { "host": "10.40.50.110", "port": 7000 } }, "database": { "technology": "postgres", "config": { "host": "10.40.50.110", "port": 5432, "user": "postgres", "password": "admin", "dbname": "metadefender_core" } }, "storage": { "technology": "h2", "config": { "host": "10.40.50.110", "port": 8888, "connection_key": "5f8214e3bba948f5a921d70d5aa2966f" } }, "broker": { "technology": "rabbitmq", "config": { "host": "10.40.50.110", "port": 5672, "user": "admin", "password": "admin" } }}