Moved to rails4 default settings.

This commit is contained in:
Martin Edenhofer 2013-09-20 14:54:33 +02:00
parent 0ed5cbe741
commit 1d6c4c68e7
3 changed files with 29 additions and 7 deletions

View file

@ -6,6 +6,9 @@ Zammad::Application.configure do
# since you don't have to restart the web server when you make code changes. # since you don't have to restart the web server when you make code changes.
config.cache_classes = false config.cache_classes = false
# Do not eager load code on boot.
config.eager_load = false
# Show full error reports and disable caching # Show full error reports and disable caching
config.consider_all_requests_local = true config.consider_all_requests_local = true
config.action_controller.perform_caching = false config.action_controller.perform_caching = false
@ -16,8 +19,8 @@ Zammad::Application.configure do
# Print deprecation notices to the Rails logger # Print deprecation notices to the Rails logger
config.active_support.deprecation = :log config.active_support.deprecation = :log
# Only use best-standards-support built into browsers # Raise an error on page load if there are pending migrations
config.action_dispatch.best_standards_support = :builtin config.active_record.migration_error = :page_load
# Do not compress assets # Do not compress assets
config.assets.compress = false config.assets.compress = false

View file

@ -4,6 +4,12 @@ Zammad::Application.configure do
# Code is not reloaded between requests # Code is not reloaded between requests
config.cache_classes = true config.cache_classes = true
# Eager load code on boot. This eager loads most of Rails and
# your application in memory, allowing both thread web servers
# and those relying on copy on write to perform better.
# Rake tasks automatically ignore this option for performance.
config.eager_load = true
# Full error reports are disabled and caching is turned on # Full error reports are disabled and caching is turned on
config.consider_all_requests_local = false config.consider_all_requests_local = false
config.action_controller.perform_caching = true config.action_controller.perform_caching = true
@ -14,14 +20,18 @@ Zammad::Application.configure do
# Compress JavaScripts and CSS # Compress JavaScripts and CSS
config.assets.compress = true config.assets.compress = true
# Compress JavaScripts and CSS.
config.assets.js_compressor = :uglifier
# config.assets.css_compressor = :sass
# Don't fallback to assets pipeline if a precompiled asset is missed # Don't fallback to assets pipeline if a precompiled asset is missed
config.assets.compile = false config.assets.compile = false
# Generate digests for assets URLs # Generate digests for assets URLs
config.assets.digest = true config.assets.digest = true
# Defaults to Rails.root.join("public/assets") # Version of your assets, change this if you want to expire all your assets.
# config.assets.manifest = YOUR_PATH config.assets.version = '1.0'
# Specifies the header that your server uses for sending files # Specifies the header that your server uses for sending files
# config.action_dispatch.x_sendfile_header = "X-Sendfile" # for apache # config.action_dispatch.x_sendfile_header = "X-Sendfile" # for apache
@ -32,6 +42,7 @@ Zammad::Application.configure do
# See everything in the log (default is :info) # See everything in the log (default is :info)
# config.log_level = :debug # config.log_level = :debug
config.log_level = :info
# Prepend all log lines with the following tags # Prepend all log lines with the following tags
# config.log_tags = [ :subdomain, :uuid ] # config.log_tags = [ :subdomain, :uuid ]
@ -51,9 +62,6 @@ Zammad::Application.configure do
# Disable delivery errors, bad email addresses will be ignored # Disable delivery errors, bad email addresses will be ignored
# config.action_mailer.raise_delivery_errors = false # config.action_mailer.raise_delivery_errors = false
# Enable threaded mode
# config.threadsafe!
# Enable locale fallbacks for I18n (makes lookups for any locale fall back to # Enable locale fallbacks for I18n (makes lookups for any locale fall back to
# the I18n.default_locale when a translation can not be found) # the I18n.default_locale when a translation can not be found)
config.i18n.fallbacks = true config.i18n.fallbacks = true
@ -61,6 +69,12 @@ Zammad::Application.configure do
# Send deprecation notices to registered listeners # Send deprecation notices to registered listeners
config.active_support.deprecation = :notify config.active_support.deprecation = :notify
# Disable automatic flushing of the log to improve performance.
# config.autoflush_log = false
# autoload on # autoload on
config.dependency_loading = true config.dependency_loading = true
# Use default logging formatter so that PID and timestamp are not suppressed.
config.log_formatter = ::Logger::Formatter.new
end end

View file

@ -7,6 +7,11 @@ Zammad::Application.configure do
# and recreated between test runs. Don't rely on the data there! # and recreated between test runs. Don't rely on the data there!
config.cache_classes = true config.cache_classes = true
# Do not eager load code on boot. This avoids loading your whole application
# just for the purpose of running a single test. If you are using a tool that
# preloads Rails for running tests, you may have to set it to true.
config.eager_load = false
# Configure static asset server for tests with Cache-Control for performance # Configure static asset server for tests with Cache-Control for performance
config.serve_static_assets = true config.serve_static_assets = true
config.static_cache_control = "public, max-age=3600" config.static_cache_control = "public, max-age=3600"