You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Previously, there was a small amount of grouping of related config
options. However, the lack of an ordered list made options feel less
discoverable than when they are sorted.
In addition, filled in descriptions for a number of config options that
were missing.
Copy file name to clipboardExpand all lines: guides/source/configuring.md
+107-1Lines changed: 107 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -169,10 +169,20 @@ config.after_initialize do
169
169
end
170
170
```
171
171
172
+
#### `config.allow_concurrency`
173
+
174
+
Controls whether requests should be handled concurrently. This should only
175
+
be set to `false` if application code is not thread safe. Defaults to `true`.
176
+
172
177
#### `config.asset_host`
173
178
174
179
Sets the host for the assets. Useful when CDNs are used for hosting assets, or when you want to work around the concurrency constraints built-in in browsers using different domain aliases. Shorter version of `config.action_controller.asset_host`.
175
180
181
+
#### `config.autoflush_log`
182
+
183
+
Enables writing log file output immediately instead of buffering. Defaults to
184
+
`true`.
185
+
176
186
#### `config.autoload_once_paths`
177
187
178
188
Accepts an array of paths from which Rails will autoload constants that won't be wiped per request. Relevant if reloading is enabled, which it is by default in the `development` environment. Otherwise, all autoloading happens only once. All elements of this array must also be in `autoload_paths`. Default is an empty array.
The redirect filter works by testing that urls include strings or match regular
312
+
expressions.
313
+
280
314
#### `config.force_ssl`
281
315
282
316
Forces all requests to be served over HTTPS, and sets "https://" as the default protocol when generating URLs. Enforcement of HTTPS is handled by the `ActionDispatch::SSL` middleware, which can be configured via `config.ssl_options`.
283
317
318
+
#### `config.helpers_paths`
319
+
320
+
Defines an array of additional paths to load view helpers.
321
+
322
+
#### `config.host_authorization`
323
+
324
+
Accepts a hash of options to configure the [HostAuthorization
325
+
middleware](#actiondispatch-hostauthorization)
326
+
327
+
#### `config.hosts`
328
+
329
+
An array of strings, regular expressions, or `IPAddr` used to validate the
330
+
`Host` header. Used by the [HostAuthorization
331
+
middleware](#actiondispatch-hostauthorization) to help prevent DNS rebinding
332
+
attacks.
333
+
284
334
#### `config.javascript_path`
285
335
286
336
Sets the path where your app's JavaScript lives relative to the `app` directory. The default is `javascript`, used by [webpacker](https://github.com/rails/webpacker). An app's configured `javascript_path` will be excluded from `autoload_paths`.
@@ -327,10 +377,33 @@ Allows you to configure the application's middleware. This is covered in depth i
327
377
328
378
Configures Rails to serve static files from the public directory. This option defaults to `true`, but in the production environment it is set to `false` because the server software (e.g. NGINX or Apache) used to run the application should serve static files instead. If you are running or testing your app in production using WEBrick (it is not recommended to use WEBrick in production) set the option to `true`. Otherwise, you won't be able to use page caching and request for files that exist under the public directory.
329
379
380
+
#### `config.railties_order`
381
+
382
+
Allows manually specifying the order that Railties/Engines are loaded. The
When `true`, will try to read encrypted secrets from `config/secrets.yml.enc`
400
+
401
+
#### `config.relative_url_root`
402
+
403
+
Can be used to tell Rails that you are [deploying to a subdirectory](
404
+
configuring.html#deploy-to-a-subdirectory-relative-url-root). The default
405
+
is `ENV['RAILS_RELATIVE_URL_ROOT']`.
406
+
334
407
#### `config.reload_classes_only_on_change`
335
408
336
409
Enables or disables reloading of classes only when tracked files change. By default tracks everything on autoload paths and is set to `true`. If `config.enable_reloading` is `false`, this option is ignored.
@@ -347,6 +420,21 @@ in `config/credentials.yml.enc`. See the [`secret_key_base` API documentation](
Specifies what class to use to store the session. Possible values are `:cache_store`, `:cookie_store`, `:mem_cache_store`, a custom store, or `:disabled`. `:disabled` tells Rails not to deal with sessions.
@@ -381,6 +469,17 @@ The default value depends on the `config.load_defaults` target version:
381
469
382
470
Sets the default time zone for the application and enables time zone awareness for Active Record.
383
471
472
+
#### `config.x`
473
+
474
+
Used to easily add nested custom configuration to the application config object
Adds metrics to the `Server-Timing` header to be viewed in the dev tools of a
647
+
browser.
648
+
545
649
#### `ActionDispatch::SSL`
546
650
547
651
Forces every request to be served using HTTPS. Enabled if `config.force_ssl` is set to `true`. Options passed to this can be configured by setting `config.ssl_options`.
@@ -1158,7 +1262,9 @@ The default value depends on the `config.load_defaults` target version:
1158
1262
1159
1263
#### `config.action_controller.relative_url_root`
1160
1264
1161
-
Can be used to tell Rails that you are [deploying to a subdirectory](configuring.html#deploy-to-a-subdirectory-relative-url-root). The default is `ENV['RAILS_RELATIVE_URL_ROOT']`.
1265
+
Can be used to tell Rails that you are [deploying to a subdirectory](
1266
+
configuring.html#deploy-to-a-subdirectory-relative-url-root). The default is
0 commit comments