Logging

Log levels, files, syslog and console colours


Variable Choices/Defaults Comments
LOG_LEVEL
string
Choices:
  • error
  • warn
  • notice (default)
  • info
  • debug

Log level
emerg, alert, crit, error, warning, notice, info, debug

Ansible Forms logs to logfile called Ansible Forms.log.
It does so in multiple levels.

LOG_PATH
string
Default:
%PERSISTENT_FOLDER%/logs

Path for logfiles
a valid folder path

Ansible Forms maintains 2 logfiles. ansibleforms.log and ansibleforms.errors.log

Added 4.0.0

Make the logfiles rotating with daily timestamp. 30days of logs are kept.

LOG_CONSOLE_LEVEL
string
Choices:
  • error
  • warn
  • notice (default)
  • info
  • debug

Console log level
emerg, alert, crit, error, warning, notice, info, debug

When you run ansibleforms, by default the application also logs to the console.
For example with docker you can use the command docker logs to access this console log.
This console log has a seperate loglevel.

LOG_TZ
string
added in version 5.0.10
Default:
UTC

Log timezone
a valid timezone string

Sets the timezone for log timestamps. Use a valid IANA timezone string (e.g., UTC, Europe/Amsterdam, America/New_York). Also used for the job timestamps.

LOG_SYSLOG_HOST
string
added in version 3.0.1
Default:

Syslog host
a valid IP or FQDN

Setting the syslog host enables the logging to a syslog server. Without it, nothing is sent to syslog.

LOG_SYSLOG_LEVEL
string
added in version 3.0.1
Choices:
  • error
  • warn
  • notice
  • info
  • debug (default)

Syslog level
emerg, alert, crit, error, warning, notice, info, debug

The logging level for the syslog server

LOG_SYSLOG_PORT
number
added in version 3.0.1
Default:
514

Syslog port
valid tcp/udp port number

The port on which the syslog server is listening

LOG_SYSLOG_PROTOCOL
string
added in version 3.0.1
Choices:
  • tcp4
  • udp4 (default)
  • tls4
  • unix
  • unix-connect

Syslog protocol
udp, udp4, udp6, tcp, tcp4, tcp6, tls, tls4, tls6, unix, unix-connect

The syslog protocol to use

LOG_SYSLOG_PATH
string
added in version 3.0.1
Default:
/dev/log

Syslog path
valid syslog path

The path to the syslog dgram socket (i.e. /dev/log or /var/run/syslog for OS X)

LOG_SYSLOG_SOURCE
string
added in version 3.0.1
Default:
localhost

Source hostname
hostname

Host to indicate where log messages are coming from

LOG_SYSLOG_TYPE
string
added in version 3.0.1
Choices:
  • BSD (default)
  • 3164
  • 5424
  • RFC3164
  • RFC5424

Syslog protocol type
BSD, 5424

The type of the syslog protocol to use

LOG_SYSLOG_APPNAME
string
added in version 3.0.1
Default:
AnsibleForms

App name
free text

The name of the application

LOG_COLOR_ERROR
string
added in version 3.0.1
Default:
\x1b[31m

Error color code
valid escape color code

The escape color code for error (default red)

LOG_COLOR_WARN
string
added in version 3.0.1
Default:
\x1b[33m

Warning color code
valid escape color code

The escape color code for warning (default yellow)

LOG_COLOR_NOTICE
string
added in version 3.0.1
Default:
\x1b[37m

Notice color code
valid escape color code

The escape color code for notice (default white)

LOG_COLOR_INFO
string
added in version 3.0.1
Default:
\x1b[32m

Info color code
valid escape color code

The escape color code for info (default green)

LOG_COLOR_DEBUG
string
added in version 3.0.1
Default:
\x1b[36m

Debug color code
valid escape color code

The escape color code for debug (default cyan)


Copyright © 2023-2026 AnsibleForms. All rights reserved.

This site uses Just the Docs, a documentation theme for Jekyll.