Make syslog logging handler optional
This commit makes the inclusion of configuration for the syslog handler conditional, based on the value of horizon::log_handler. Change-Id: I284ffb7ca97ec7548bc9d98674d4a92d01c319ba Closes-Bug: #1563239
This commit is contained in:
parent
3579bde5de
commit
8d70201feb
@ -36,7 +36,6 @@ ALLOWED_HOSTS = ['<%= @final_allowed_hosts.join("', '") %>', ]
|
|||||||
<% else %>
|
<% else %>
|
||||||
ALLOWED_HOSTS = ['<%= @final_allowed_hosts %>', ]
|
ALLOWED_HOSTS = ['<%= @final_allowed_hosts %>', ]
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
# Set SSL proxy settings:
|
# Set SSL proxy settings:
|
||||||
# Pass this header from the proxy after terminating the SSL,
|
# Pass this header from the proxy after terminating the SSL,
|
||||||
# and don't forget to strip it from the client's request.
|
# and don't forget to strip it from the client's request.
|
||||||
@ -612,6 +611,7 @@ LOGGING = {
|
|||||||
'filename': '<%= scope.lookupvar("horizon::params::logdir") %>/horizon.log',
|
'filename': '<%= scope.lookupvar("horizon::params::logdir") %>/horizon.log',
|
||||||
'formatter': 'verbose',
|
'formatter': 'verbose',
|
||||||
},
|
},
|
||||||
|
<%- if @log_handler == 'syslog' -%>
|
||||||
'syslog': {
|
'syslog': {
|
||||||
'level': '<%= @log_level %>',
|
'level': '<%= @log_level %>',
|
||||||
'facility': 'local1',
|
'facility': 'local1',
|
||||||
@ -619,6 +619,7 @@ LOGGING = {
|
|||||||
'address': '/dev/log',
|
'address': '/dev/log',
|
||||||
'formatter': 'normal',
|
'formatter': 'normal',
|
||||||
}
|
}
|
||||||
|
<%- end -%>
|
||||||
},
|
},
|
||||||
'loggers': {
|
'loggers': {
|
||||||
# Logging from django.db.backends is VERY verbose, send to null
|
# Logging from django.db.backends is VERY verbose, send to null
|
||||||
|
Loading…
x
Reference in New Issue
Block a user