|
22 | 22 | # Apache or NGINX already handles this.
|
23 | 23 | config.public_file_server.enabled = ENV['RAILS_SERVE_STATIC_FILES'].present?
|
24 | 24 |
|
25 |
| - # Compress JavaScripts and CSS. |
26 |
| - config.assets.js_compressor = :uglifier |
| 25 | + # Compress CSS using a preprocessor. |
27 | 26 | # config.assets.css_compressor = :sass
|
28 | 27 |
|
29 | 28 | # Do not fallback to assets pipeline if a precompiled asset is missed.
|
30 | 29 | config.assets.compile = false
|
31 | 30 |
|
32 |
| - # `config.assets.precompile` and `config.assets.version` have moved to config/initializers/assets.rb |
33 |
| - |
34 | 31 | # Enable serving of images, stylesheets, and JavaScripts from an asset server.
|
35 | 32 | # config.action_controller.asset_host = 'http://assets.example.com'
|
36 | 33 |
|
37 | 34 | # Specifies the header that your server uses for sending files.
|
38 | 35 | # config.action_dispatch.x_sendfile_header = 'X-Sendfile' # for Apache
|
39 | 36 | # config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect' # for NGINX
|
40 | 37 |
|
41 |
| - # Store uploaded files on the local file system (see config/storage.yml for options) |
| 38 | + # Store uploaded files on the local file system (see config/storage.yml for options). |
42 | 39 | config.active_storage.service = :local
|
43 | 40 |
|
44 |
| - # Mount Action Cable outside main process or domain |
| 41 | + # Mount Action Cable outside main process or domain. |
45 | 42 | # config.action_cable.mount_path = nil
|
46 | 43 | # config.action_cable.url = 'wss://example.com/cable'
|
47 | 44 | # config.action_cable.allowed_request_origins = [ 'http://example.com', /http:\/\/example.*/ ]
|
|
59 | 56 | # Use a different cache store in production.
|
60 | 57 | # config.cache_store = :mem_cache_store
|
61 | 58 |
|
62 |
| - # Use a real queuing backend for Active Job (and separate queues per environment) |
| 59 | + # Use a real queuing backend for Active Job (and separate queues per environment). |
63 | 60 | # config.active_job.queue_adapter = :resque
|
64 |
| - # config.active_job.queue_name_prefix = "medireco_#{Rails.env}" |
| 61 | + # config.active_job.queue_name_prefix = "medireco_production" |
65 | 62 |
|
66 | 63 | config.action_mailer.perform_caching = false
|
67 | 64 |
|
|
91 | 88 |
|
92 | 89 | # Do not dump schema after migrations.
|
93 | 90 | config.active_record.dump_schema_after_migration = false
|
| 91 | + |
| 92 | + # Inserts middleware to perform automatic connection switching. |
| 93 | + # The `database_selector` hash is used to pass options to the DatabaseSelector |
| 94 | + # middleware. The `delay` is used to determine how long to wait after a write |
| 95 | + # to send a subsequent read to the primary. |
| 96 | + # |
| 97 | + # The `database_resolver` class is used by the middleware to determine which |
| 98 | + # database is appropriate to use based on the time delay. |
| 99 | + # |
| 100 | + # The `database_resolver_context` class is used by the middleware to set |
| 101 | + # timestamps for the last write to the primary. The resolver uses the context |
| 102 | + # class timestamps to determine how long to wait before reading from the |
| 103 | + # replica. |
| 104 | + # |
| 105 | + # By default Rails will store a last write timestamp in the session. The |
| 106 | + # DatabaseSelector middleware is designed as such you can define your own |
| 107 | + # strategy for connection switching and pass that into the middleware through |
| 108 | + # these configuration options. |
| 109 | + # config.active_record.database_selector = { delay: 2.seconds } |
| 110 | + # config.active_record.database_resolver = ActiveRecord::Middleware::DatabaseSelector::Resolver |
| 111 | + # config.active_record.database_resolver_context = ActiveRecord::Middleware::DatabaseSelector::Resolver::Session |
94 | 112 | end
|
0 commit comments