parent
62e8f87f2c
commit
5655eead7c
4 changed files with 40 additions and 12 deletions
|
|
@ -56,6 +56,7 @@
|
||||||
* Add popover/tooltip about email visibility to registration/settings page [#5956](https://github.com/diaspora/diaspora/pull/5956)
|
* Add popover/tooltip about email visibility to registration/settings page [#5956](https://github.com/diaspora/diaspora/pull/5956)
|
||||||
* Fetch person posts on sharing request [#5960](https://github.com/diaspora/diaspora/pull/5960)
|
* Fetch person posts on sharing request [#5960](https://github.com/diaspora/diaspora/pull/5960)
|
||||||
* Introduce 'authorized' configuration option for services [#5985](https://github.com/diaspora/diaspora/pull/5985)
|
* Introduce 'authorized' configuration option for services [#5985](https://github.com/diaspora/diaspora/pull/5985)
|
||||||
|
* Added configuration options for log rotating [#5994](https://github.com/diaspora/diaspora/pull/5994)
|
||||||
|
|
||||||
# 0.5.0.1
|
# 0.5.0.1
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -31,6 +31,10 @@ defaults:
|
||||||
upload: false
|
upload: false
|
||||||
host:
|
host:
|
||||||
pubsub_server: 'https://pubsubhubbub.appspot.com/'
|
pubsub_server: 'https://pubsubhubbub.appspot.com/'
|
||||||
|
logging:
|
||||||
|
logrotate:
|
||||||
|
enable: true
|
||||||
|
days: 7
|
||||||
server:
|
server:
|
||||||
port:
|
port:
|
||||||
listen: '0.0.0.0:3000'
|
listen: '0.0.0.0:3000'
|
||||||
|
|
|
||||||
|
|
@ -138,6 +138,17 @@ configuration: ## Section
|
||||||
## You probably don't want to uncomment or change this.
|
## You probably don't want to uncomment or change this.
|
||||||
#pubsub_server: 'https://pubsubhubbub.appspot.com/'
|
#pubsub_server: 'https://pubsubhubbub.appspot.com/'
|
||||||
|
|
||||||
|
## Logger configuration
|
||||||
|
logging: ## Section
|
||||||
|
|
||||||
|
logrotate: ## Section
|
||||||
|
|
||||||
|
## Roll the application log on a daily basis (default=true).
|
||||||
|
#enable: true
|
||||||
|
|
||||||
|
## The number of days to keep (default=7)
|
||||||
|
#days: 7
|
||||||
|
|
||||||
## Settings affecting how ./script/server behaves.
|
## Settings affecting how ./script/server behaves.
|
||||||
server: ## Section
|
server: ## Section
|
||||||
## Where the appserver should listen to (default=0.0.0.0:3000)
|
## Where the appserver should listen to (default=0.0.0.0:3000)
|
||||||
|
|
|
||||||
|
|
@ -36,18 +36,30 @@ Logging::Rails.configure do |config|
|
||||||
)
|
)
|
||||||
) if config.log_to.include? "stdout"
|
) if config.log_to.include? "stdout"
|
||||||
|
|
||||||
# Configure an appender that will write log events to a file. The file will
|
if config.log_to.include? "file"
|
||||||
# be rolled on a daily basis, and the past 7 rolled files will be kept.
|
# Configure an appender that will write log events to a file.
|
||||||
# Older files will be deleted. The default pattern layout is used when
|
if AppConfig.environment.logging.logrotate.enable?
|
||||||
# formatting log events into strings.
|
# The file will be rolled on a daily basis, and the rolled files will be kept
|
||||||
Logging.appenders.rolling_file("file",
|
# the configured number of days. Older files will be deleted. The default pattern
|
||||||
filename: config.paths["log"].first,
|
# layout is used when formatting log events into strings.
|
||||||
keep: 7,
|
Logging.appenders.rolling_file("file",
|
||||||
age: "daily",
|
filename: config.paths["log"].first,
|
||||||
truncate: false,
|
keep: AppConfig.environment.logging.logrotate.days.to_i,
|
||||||
auto_flushing: true,
|
age: "daily",
|
||||||
layout: layout
|
truncate: false,
|
||||||
) if config.log_to.include? "file"
|
auto_flushing: true,
|
||||||
|
layout: layout
|
||||||
|
)
|
||||||
|
else
|
||||||
|
# No file rolling, use logrotate to roll the logfile.
|
||||||
|
Logging.appenders.file("file",
|
||||||
|
filename: config.paths["log"].first,
|
||||||
|
truncate: false,
|
||||||
|
auto_flushing: true,
|
||||||
|
layout: layout
|
||||||
|
)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
# Setup the root logger with the Rails log level and the desired set of
|
# Setup the root logger with the Rails log level and the desired set of
|
||||||
# appenders. The list of appenders to use should be set in the environment
|
# appenders. The list of appenders to use should be set in the environment
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue