]> git.openstreetmap.org Git - rails.git/blob - config/initializers/new_framework_defaults_7_1.rb
Fix file dimensions and switch from png to jpg
[rails.git] / config / initializers / new_framework_defaults_7_1.rb
1 # Be sure to restart your server when you modify this file.
2 #
3 # This file eases your Rails 7.1 framework defaults upgrade.
4 #
5 # Uncomment each configuration one by one to switch to the new default.
6 # Once your application is ready to run with all new defaults, you can remove
7 # this file and set the `config.load_defaults` to `7.1`.
8 #
9 # Read the Guide for Upgrading Ruby on Rails for more info on each option.
10 # https://guides.rubyonrails.org/upgrading_ruby_on_rails.html
11
12 # No longer add autoloaded paths into `$LOAD_PATH`. This means that you won't be able
13 # to manually require files that are managed by the autoloader, which you shouldn't do anyway.
14 # This will reduce the size of the load path, making `require` faster if you don't use bootsnap, or reduce the size
15 # of the bootsnap cache if you use it.
16 # Rails.application.config.add_autoload_paths_to_load_path = false
17
18 # Remove the default X-Download-Options headers since it is used only by Internet Explorer.
19 # If you need to support Internet Explorer, add back `"X-Download-Options" => "noopen"`.
20 # Rails.application.config.action_dispatch.default_headers = {
21 #   "X-Frame-Options" => "SAMEORIGIN",
22 #   "X-XSS-Protection" => "0",
23 #   "X-Content-Type-Options" => "nosniff",
24 #   "X-Permitted-Cross-Domain-Policies" => "none",
25 #   "Referrer-Policy" => "strict-origin-when-cross-origin"
26 # }
27
28 # Do not treat an `ActionController::Parameters` instance
29 # as equal to an equivalent `Hash` by default.
30 # Rails.application.config.action_controller.allow_deprecated_parameters_hash_equality = false
31
32 # Active Record Encryption now uses SHA-256 as its hash digest algorithm. Important: If you have
33 # data encrypted with previous Rails versions, there are two scenarios to consider:
34 #
35 # 1. If you have +config.active_support.key_generator_hash_digest_class+ configured as SHA1 (the default
36 # before Rails 7.0), you need to configure SHA-1 for Active Record Encryption too:
37 # Rails.application.config.active_record.encryption.hash_digest_class = OpenSSL::Digest::SHA1
38 # 2. If you have +config.active_support.key_generator_hash_digest_class+ configured as SHA256 (the new default
39 # in 7.0), then you need to configure SHA-256 for Active Record Encryption:
40 # Rails.application.config.active_record.encryption.hash_digest_class = OpenSSL::Digest::SHA256
41 #
42 # If you don't currently have data encrypted with Active Record encryption, you can disable this setting to
43 # configure the default behavior starting 7.1+:
44 # Rails.application.config.active_record.encryption.support_sha1_for_non_deterministic_encryption = false
45
46 # No longer run after_commit callbacks on the first of multiple Active Record
47 # instances to save changes to the same database row within a transaction.
48 # Instead, run these callbacks on the instance most likely to have internal
49 # state which matches what was committed to the database, typically the last
50 # instance to save.
51 # Rails.application.config.active_record.run_commit_callbacks_on_first_saved_instances_in_transaction = false
52
53 # Configures SQLite with a strict strings mode, which disables double-quoted string literals.
54 #
55 # SQLite has some quirks around double-quoted string literals.
56 # It first tries to consider double-quoted strings as identifier names, but if they don't exist
57 # it then considers them as string literals. Because of this, typos can silently go unnoticed.
58 # For example, it is possible to create an index for a non existing column.
59 # See https://www.sqlite.org/quirks.html#double_quoted_string_literals_are_accepted for more details.
60 # Rails.application.config.active_record.sqlite3_adapter_strict_strings_by_default = true
61
62 # Disable deprecated singular associations names
63 # Rails.application.config.active_record.allow_deprecated_singular_associations_name = false
64
65 # Enable the Active Job `BigDecimal` argument serializer, which guarantees
66 # roundtripping. Without this serializer, some queue adapters may serialize
67 # `BigDecimal` arguments as simple (non-roundtrippable) strings.
68 #
69 # When deploying an application with multiple replicas, old (pre-Rails 7.1)
70 # replicas will not be able to deserialize `BigDecimal` arguments from this
71 # serializer. Therefore, this setting should only be enabled after all replicas
72 # have been successfully upgraded to Rails 7.1.
73 # Rails.application.config.active_job.use_big_decimal_serializer = true
74
75 # Specify if an `ArgumentError` should be raised if `Rails.cache` `fetch` or
76 # `write` are given an invalid `expires_at` or `expires_in` time.
77 # Options are `true`, and `false`. If `false`, the exception will be reported
78 # as `handled` and logged instead.
79 # Rails.application.config.active_support.raise_on_invalid_cache_expiration_time = true
80
81 # Specify whether Query Logs will format tags using the SQLCommenter format
82 # (https://open-telemetry.github.io/opentelemetry-sqlcommenter/), or using the legacy format.
83 # Options are `:legacy` and `:sqlcommenter`.
84 # Rails.application.config.active_record.query_log_tags_format = :sqlcommenter
85
86 # Specify the default serializer used by `MessageEncryptor` and `MessageVerifier`
87 # instances.
88 #
89 # The legacy default is `:marshal`, which is a potential vector for
90 # deserialization attacks in cases where a message signing secret has been
91 # leaked.
92 #
93 # In Rails 7.1, the new default is `:json_allow_marshal` which serializes and
94 # deserializes with `ActiveSupport::JSON`, but can fall back to deserializing
95 # with `Marshal` so that legacy messages can still be read.
96 #
97 # In Rails 7.2, the default will become `:json` which serializes and
98 # deserializes with `ActiveSupport::JSON` only.
99 #
100 # Alternatively, you can choose `:message_pack` or `:message_pack_allow_marshal`,
101 # which serialize with `ActiveSupport::MessagePack`. `ActiveSupport::MessagePack`
102 # can roundtrip some Ruby types that are not supported by JSON, and may provide
103 # improved performance, but it requires the `msgpack` gem.
104 #
105 # For more information, see
106 # https://guides.rubyonrails.org/v7.1/configuring.html#config-active-support-message-serializer
107 #
108 # If you are performing a rolling deploy of a Rails 7.1 upgrade, wherein servers
109 # that have not yet been upgraded must be able to read messages from upgraded
110 # servers, first deploy without changing the serializer, then set the serializer
111 # in a subsequent deploy.
112 # Rails.application.config.active_support.message_serializer = :json_allow_marshal
113
114 # Enable a performance optimization that serializes message data and metadata
115 # together. This changes the message format, so messages serialized this way
116 # cannot be read by older versions of Rails. However, messages that use the old
117 # format can still be read, regardless of whether this optimization is enabled.
118 #
119 # To perform a rolling deploy of a Rails 7.1 upgrade, wherein servers that have
120 # not yet been upgraded must be able to read messages from upgraded servers,
121 # leave this optimization off on the first deploy, then enable it on a
122 # subsequent deploy.
123 # Rails.application.config.active_support.use_message_serializer_for_metadata = true
124
125 # Set the maximum size for Rails log files.
126 #
127 # `config.load_defaults 7.1` does not set this value for environments other than
128 # development and test.
129 #
130 # if Rails.env.local?
131 #   Rails.application.config.log_file_size = 100 * 1024 * 1024
132 # end
133
134 # Enable raising on assignment to attr_readonly attributes. The previous
135 # behavior would allow assignment but silently not persist changes to the
136 # database.
137 # Rails.application.config.active_record.raise_on_assign_to_attr_readonly = true
138
139 # Enable validating only parent-related columns for presence when the parent is mandatory.
140 # The previous behavior was to validate the presence of the parent record, which performed an extra query
141 # to get the parent every time the child record was updated, even when parent has not changed.
142 # Rails.application.config.active_record.belongs_to_required_validates_foreign_key = false
143
144 # Enable precompilation of `config.filter_parameters`. Precompilation can
145 # improve filtering performance, depending on the quantity and types of filters.
146 # Rails.application.config.precompile_filter_parameters = true
147
148 # Enable before_committed! callbacks on all enrolled records in a transaction.
149 # The previous behavior was to only run the callbacks on the first copy of a record
150 # if there were multiple copies of the same record enrolled in the transaction.
151 # Rails.application.config.active_record.before_committed_on_all_records = true
152
153 # Disable automatic column serialization into YAML.
154 # To keep the historic behavior, you can set it to `YAML`, however it is
155 # recommended to explicitly define the serialization method for each column
156 # rather than to rely on a global default.
157 # Rails.application.config.active_record.default_column_serializer = nil
158
159 # Enable a performance optimization that serializes Active Record models
160 # in a faster and more compact way.
161 #
162 # To perform a rolling deploy of a Rails 7.1 upgrade, wherein servers that have
163 # not yet been upgraded must be able to read caches from upgraded servers,
164 # leave this optimization off on the first deploy, then enable it on a
165 # subsequent deploy.
166 # Rails.application.config.active_record.marshalling_format_version = 7.1
167
168 # Run `after_commit` and `after_*_commit` callbacks in the order they are defined in a model.
169 # This matches the behaviour of all other callbacks.
170 # In previous versions of Rails, they ran in the inverse order.
171 # Rails.application.config.active_record.run_after_transaction_callbacks_in_order_defined = true
172
173 # Whether a `transaction` block is committed or rolled back when exited via `return`, `break` or `throw`.
174 #
175 # Rails.application.config.active_record.commit_transaction_on_non_local_return = true
176
177 # Controls when to generate a value for <tt>has_secure_token</tt> declarations.
178 #
179 # Rails.application.config.active_record.generate_secure_token_on = :initialize
180
181 # ** Please read carefully, this must be configured in config/application.rb **
182 # Change the format of the cache entry.
183 # Changing this default means that all new cache entries added to the cache
184 # will have a different format that is not supported by Rails 7.0
185 # applications.
186 # Only change this value after your application is fully deployed to Rails 7.1
187 # and you have no plans to rollback.
188 # When you're ready to change format, add this to `config/application.rb` (NOT
189 # this file):
190 #   config.active_support.cache_format_version = 7.1
191
192 # Configure Action View to use HTML5 standards-compliant sanitizers when they are supported on your
193 # platform.
194 #
195 # `Rails::HTML::Sanitizer.best_supported_vendor` will cause Action View to use HTML5-compliant
196 # sanitizers if they are supported, else fall back to HTML4 sanitizers.
197 #
198 # In previous versions of Rails, Action View always used `Rails::HTML4::Sanitizer` as its vendor.
199 #
200 # Rails.application.config.action_view.sanitizer_vendor = Rails::HTML::Sanitizer.best_supported_vendor
201
202 # Configure Action Text to use an HTML5 standards-compliant sanitizer when it is supported on your
203 # platform.
204 #
205 # `Rails::HTML::Sanitizer.best_supported_vendor` will cause Action Text to use HTML5-compliant
206 # sanitizers if they are supported, else fall back to HTML4 sanitizers.
207 #
208 # In previous versions of Rails, Action Text always used `Rails::HTML4::Sanitizer` as its vendor.
209 #
210 # Rails.application.config.action_text.sanitizer_vendor = Rails::HTML::Sanitizer.best_supported_vendor
211
212 # Configure the log level used by the DebugExceptions middleware when logging
213 # uncaught exceptions during requests
214 # Rails.application.config.action_dispatch.debug_exception_log_level = :error
215
216 # Configure the test helpers in Action View, Action Dispatch, and rails-dom-testing to use HTML5
217 # parsers.
218 #
219 # Nokogiri::HTML5 isn't supported on JRuby, so JRuby applications must set this to :html4.
220 #
221 # In previous versions of Rails, these test helpers always used an HTML4 parser.
222 #
223 # Rails.application.config.dom_testing_default_html_version = :html5