Commit graph

51 commits

Author SHA1 Message Date
Tom Hughes
a218fcccbb Switch to rails 7.2 defaults 2024-10-02 19:16:37 +01:00
Gregory Igelmund
6eb29bf6d4 Set config.active_model.i18n_customize_full_message = true
Enables better error message customization
2023-12-19 12:57:47 -05:00
Tom Hughes
6f60111c92 Switch to rails 7.1 defaults 2023-10-27 18:00:05 +01:00
Tom Hughes
e331266687 Enable rails 7.1 defaults that relate to rolling upgrades 2023-10-26 22:43:29 +01:00
Tom Hughes
f37ea2fae3 Update to rails 7.1.1 2023-10-18 18:26:13 +01:00
Tom Hughes
8d7b98a618 Drop workaround to force UTF8 form upload in IE8
This has been disabled by default in rails for some time.
2023-10-07 11:57:54 +01:00
Tom Hughes
4a5d509adf Allow models to load when the database is offline
It used to be necessary to stop ActiveRecord loading because
it would immediately try and connect the database but with the
introduction of switchable database connections it now only connects
when a model is used for the first time.

Fixes #3858
2023-01-05 20:25:34 +00:00
Andy Allan
aab33eee87 Use rails 7.0 configuration defaults
All the entries in the new framework defaults were enabled a while
ago, apart from the cookies serializer which is already defined in
config/initializers/cookies_serializer.rb
2022-11-16 15:29:30 +00:00
Tom Hughes
0724ed1aeb Fix new rubocopy warnings 2022-04-26 18:10:52 +01:00
Andy Allan
619ac4c5b2 Enable active_record.belongs_to_required_by_default
This switches the logic so that belongs_to parent objects must exist
by default, and marks the optional ones explicitly. This is reflected
in the null/not_null status on the relevant db columns.
2022-02-23 20:33:28 +00:00
Tom Hughes
7de3143525 Switch to 6.1 defaults as everything has been enabled for some time 2021-12-30 19:55:13 +00:00
Tom Hughes
eada36ff96 Switch to using the zeitwork autoloader 2020-12-30 20:30:21 +00:00
Tom Hughes
e392556444 Revert "Switch to using the zeitwork autoloader"
This reverts commit 127880a73f.
2020-12-29 19:29:36 +00:00
Tom Hughes
127880a73f Switch to using the zeitwork autoloader 2020-12-29 18:42:22 +00:00
Tom Hughes
1212fbad4c Enable locale fallback in all environments 2020-06-26 20:30:48 +01:00
Andy Allan
f33f1f297e Use rails 6.0 framework defaults
Keep the old autoloader and utf-8 forms as they were, for now.
2020-06-03 13:45:07 +02:00
Tom Hughes
e7ab3de654 Move application.yml check to config initializer 2019-03-17 11:15:34 +00:00
Tom Hughes
141df02e67 Move status into the settings object
Only the very early boot code needs to look at the value
from the environment directly.
2019-03-17 11:15:34 +00:00
Tom Hughes
6600221fe3 Fix database offline mode 2019-03-17 11:15:34 +00:00
Andy Allan
fd47078b14 Provide a helpful warning if there's an application.yml file detected 2019-03-13 18:20:08 +01:00
Andy Allan
9af31c2254 Only take the STATUS configuration from the environment
This allows us to remove the preinitializer-based configuration parsing.
2019-03-13 18:06:23 +01:00
Andy Allan
d102c9aaf4 Move all settings to settings.yml
We leave the STATUS setting alone, since it's required before rails
boots. The test-specific settings now live in config/settings/test.yml
2019-03-13 18:06:23 +01:00
Tom Hughes
422afdbae3 Only use DelayedJob in production
In development just let the default async adaptor be used so
that people don't need to run a daemon.
2018-11-03 11:57:25 +00:00
Andy Allan
801522c5c3 Set up Delayed Job as the backend for Active Job
This persists jobs into the database, and uses locking to ensure that
workers from multiple machines avoid treading on each other.

Jobs can be run by using `bundle exec rake jobs:work`

Fixes #2015
2018-10-31 15:31:32 +01:00
Tom Hughes
6a25ee9ec9 Update (as far as possible) to rails 5.2 default configuration 2018-06-19 18:53:08 +01:00
Tom Hughes
98de681e47 Update to rails 5.2.0 2018-06-19 00:16:24 +01:00
Andy Allan
a48633446b Remove image_optim config loading override
image_optim_rails loads the config files by default, and has a
built-in mechanism for per-environment configs. Forcing the config
loading in this way is unnecessary.
2018-03-28 13:52:31 +08:00
Tom Hughes
a83030dab7 Fix new rubocop warnings 2018-01-22 18:55:45 +00:00
Tom Hughes
81deb35331 Update to rails 5.0.4 2017-06-27 08:26:44 +01:00
Tom Hughes
5b33f3f8e3 Fix rubocop warnings 2017-06-02 00:08:30 +01:00
Tom Hughes
c8671c137a Update rubocop 2017-02-05 11:12:37 +00:00
Tom Hughes
284b56bee9 Use image_optim to optimize SVG assets with svgo 2015-09-13 10:48:33 +01:00
Tom Hughes
82cefb5929 Add support for generating logstash friendly logs 2015-07-19 19:24:20 +01:00
Tom Hughes
dbba67450a Fix offline mode 2015-03-09 20:54:33 +00:00
Tom Hughes
9e160ec176 Move memcached for caching if enabled regardless of environment 2015-02-22 19:21:34 +00:00
Tom Hughes
dc2a2c8ebd Standardise on double quoted strings 2015-02-20 19:47:26 +00:00
Tom Hughes
5cbd4038ed Fix rubocop style issues 2015-02-20 08:56:16 +00:00
Tom Hughes
ef7f3d800c Fix most auto-correctable rubocop issues 2015-02-20 08:56:16 +00:00
Tom Hughes
e65e41a694 Update to rails 4.2.0 2015-01-10 17:46:58 +00:00
Tom Hughes
bd402599f5 Update to rails 4.1.1 2014-07-04 19:24:25 +01:00
Tom Hughes
4ef3a884d0 Fix database offline mode 2014-07-02 11:07:52 +01:00
Tom Hughes
984c6dc114 Update to rails 4.0.0 2013-09-21 11:35:45 +01:00
Tom Hughes
ac1f210736 Replace the spam observer with simple after_save callbacks 2013-06-25 21:54:02 +01:00
Tom Hughes
0b87b003ee Fixed for offline mode 2012-03-20 13:45:10 +00:00
Tom Hughes
1340fca8f1 Turn on mass assignment protection
Require any attribute that is going to be mass assigned to be
whitelisted, and whitelist those attributes which need it
2012-03-06 08:54:45 +00:00
Tom Hughes
ee411e5154 Update to rails 3.2.0 2012-02-15 17:48:14 +00:00
Tom Hughes
0605d4aa8b Don't eager load models when the database is offline 2012-02-04 00:42:47 +00:00
Tom Hughes
2c837d896d Make database offline mode work 2011-11-14 09:42:56 +00:00
Tom Hughes
8acdba8bdd Upgrade to rails 3.1.0 2011-11-14 09:42:52 +00:00
Tom Hughes
423f5ffbc2 Use config.filter_parameters instead of filter_parameter_logging 2011-11-14 09:42:43 +00:00