Add log_file parameter
Change-Id: I958a8b28e9874be81036e6f84c89a276bf512e6d Closes-Bug: #1819417
This commit is contained in:
parent
328147a73c
commit
aed1d7264f
@ -33,6 +33,10 @@
|
|||||||
# If set to $::os_service_default, it will not log to any directory.
|
# If set to $::os_service_default, it will not log to any directory.
|
||||||
# Defaults to '/var/log/zaqar'
|
# Defaults to '/var/log/zaqar'
|
||||||
#
|
#
|
||||||
|
# [*log_file*]
|
||||||
|
# (Optional) File where logs should be stored.
|
||||||
|
# Defaults to $::os_service_default
|
||||||
|
#
|
||||||
# [*logging_context_format_string*]
|
# [*logging_context_format_string*]
|
||||||
# (Optional) Format string to use for log messages with context.
|
# (Optional) Format string to use for log messages with context.
|
||||||
# Defaults to $::os_service_default.
|
# Defaults to $::os_service_default.
|
||||||
@ -104,6 +108,7 @@ class zaqar::logging(
|
|||||||
$use_stderr = $::os_service_default,
|
$use_stderr = $::os_service_default,
|
||||||
$log_facility = $::os_service_default,
|
$log_facility = $::os_service_default,
|
||||||
$log_dir = '/var/log/zaqar',
|
$log_dir = '/var/log/zaqar',
|
||||||
|
$log_file = $::os_service_default,
|
||||||
$debug = $::os_service_default,
|
$debug = $::os_service_default,
|
||||||
$logging_context_format_string = $::os_service_default,
|
$logging_context_format_string = $::os_service_default,
|
||||||
$logging_default_format_string = $::os_service_default,
|
$logging_default_format_string = $::os_service_default,
|
||||||
@ -138,6 +143,7 @@ class zaqar::logging(
|
|||||||
use_stderr => $use_stderr,
|
use_stderr => $use_stderr,
|
||||||
syslog_log_facility => $log_facility,
|
syslog_log_facility => $log_facility,
|
||||||
log_dir => $log_dir,
|
log_dir => $log_dir,
|
||||||
|
log_file => $log_file,
|
||||||
debug => $debug,
|
debug => $debug,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -0,0 +1,4 @@
|
|||||||
|
---
|
||||||
|
features:
|
||||||
|
- |
|
||||||
|
Add the log_file option for logging.
|
@ -29,6 +29,7 @@ describe 'zaqar::logging' do
|
|||||||
:use_stderr => false,
|
:use_stderr => false,
|
||||||
:log_facility => 'LOG_FOO',
|
:log_facility => 'LOG_FOO',
|
||||||
:log_dir => '/var/log',
|
:log_dir => '/var/log',
|
||||||
|
:log_file => '/var/log/zaqar.log',
|
||||||
:debug => true,
|
:debug => true,
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
@ -54,6 +55,7 @@ describe 'zaqar::logging' do
|
|||||||
:use_journal => '<SERVICE DEFAULT>',
|
:use_journal => '<SERVICE DEFAULT>',
|
||||||
:use_stderr => '<SERVICE DEFAULT>',
|
:use_stderr => '<SERVICE DEFAULT>',
|
||||||
:log_dir => '/var/log/zaqar',
|
:log_dir => '/var/log/zaqar',
|
||||||
|
:log_file => '<SERVICE DEFAULT>',
|
||||||
:debug => '<SERVICE DEFAULT>',
|
:debug => '<SERVICE DEFAULT>',
|
||||||
)
|
)
|
||||||
end
|
end
|
||||||
@ -68,6 +70,7 @@ describe 'zaqar::logging' do
|
|||||||
:use_stderr => false,
|
:use_stderr => false,
|
||||||
:syslog_log_facility => 'LOG_FOO',
|
:syslog_log_facility => 'LOG_FOO',
|
||||||
:log_dir => '/var/log',
|
:log_dir => '/var/log',
|
||||||
|
:log_file => '/var/log/zaqar.log',
|
||||||
:debug => true,
|
:debug => true,
|
||||||
)
|
)
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user