Skip to content

Logging

Logging to file

In case you need the logs to be written to specific directory, set the logging level using the LOGGING_APPENDER_FILE_LEVEL and LOGGING_FILE_NAME environment variables, and mount the volume with the appropriate directory.

$ docker run -d --name das --publish 8080:8080 \
    --volume=/path/where/you/want/logs:/logs \
    --env=LOGGING_APPENDER_FILE_LEVEL=INFO \
    --env=LOGGING_FILE_NAME=/logs/log.log \
    ...

Logging to ELK

You can also set up logging to ELK. For this you need to specify the Logstash connection parameters: LOGSTASH_HOST and LOGSTASH_PORT.

$ docker run -d --name das --publish 8080:8080 \
    --env=LOGSTASH_HOST=ip-address-of-elk \
    --env=LOGSTASH_PORT=5959 \
    ...

Logging for BI purposes

You can configure logging for a result of each anti-spoofing check made for further analysis. To do this, mount the volume with the appropriate directory and set the INFO logging level for BI logs using the LOGGING_APPENDER_BI_LEVEL environment variable.

$ docker run -d --name das --publish 8080:8080 \
    --volume=/path/where/you/want/logs:/logs \
    --env=LOGGING_APPENDER_BI_LEVEL=INFO \
    ...

If you have enabled BI logging, you can get basic system performance metrics by calling the method /bi_report The method accepts two dates date_from and date_to forming a date range for which it needs to calculate metrics. Both dates are inclusive.

curl "http://localhost:8080/bi_report?date_from=2020-12-13&date_to=2020-12-15"