add a setting for enabling high rsyslogd verbosity

This commit is contained in:
Ryan Petrello 2020-04-23 12:04:19 -04:00
parent e7a9604896
commit e51d0b6fde
No known key found for this signature in database
GPG Key ID: F2AA5F2122351777
3 changed files with 13 additions and 0 deletions

View File

@ -810,6 +810,16 @@ register(
category=_('Logging'),
category_slug='logging',
)
register(
'LOG_AGGREGATOR_RSYSLOGD_DEBUG',
field_class=fields.BooleanField,
default=False,
label=_('Enable rsyslogd debugging'),
help_text=_('Enabled high verbosity debugging for rsyslogd. '
'Useful for debugging connection issues for external log aggregation.'),
category=_('Logging'),
category_slug='logging',
)
register(

View File

@ -22,6 +22,8 @@ def construct_rsyslog_conf_template(settings=settings):
spool_directory = '/var/lib/awx'
max_bytes = settings.MAX_EVENT_RES_DATA
if settings.LOG_AGGREGATOR_RSYSLOGD_DEBUG:
parts.append('$DebugLevel 2')
parts.extend([
'$WorkDirectory /var/lib/awx/rsyslog',
f'$MaxMessageSize {max_bytes}',

View File

@ -942,6 +942,7 @@ LOG_AGGREGATOR_VERIFY_CERT = True
LOG_AGGREGATOR_LEVEL = 'INFO'
LOG_AGGREGATOR_MAX_DISK_USAGE_GB = 1
LOG_AGGREGATOR_MAX_DISK_USAGE_PATH = '/var/lib/awx'
LOG_AGGREGATOR_RSYSLOGD_DEBUG = False
# The number of retry attempts for websocket session establishment
# If you're encountering issues establishing websockets in clustered Tower,