diff options
author | Claire <claire.github-309c@sitedethib.com> | 2023-03-16 23:12:59 +0100 |
---|---|---|
committer | Claire <claire.github-309c@sitedethib.com> | 2023-03-16 23:12:59 +0100 |
commit | 193250556cb4e6b1b3e2f9bd1ac023b290176fd4 (patch) | |
tree | 3bd6148ff028b8fe089cae9d805a7e587eaeec11 /config/application.rb | |
parent | f5daa20f2a90098c9d689c5ec9d95ce9887b3a33 (diff) | |
parent | 681dcd3fa35e886a21853ca829ff1be7f220e83a (diff) |
Merge branch 'main' into glitch-soc/merge-upstream
Conflicts: - `README.md`: Upstream changed their README, we have our own. Kept ours. - `app/helpers/application_helper.rb`: Minor code style fix upstream, on a line that is different in glitch-soc due to the different theming system. Applied the code style fix to our own code. - `app/views/settings/preferences/appearance/show.html.haml`: Code style fix on a line next to lines exclusive to glitch-soc. Applied upstream changes. - `yarn.lock`: Upstream updated a dependency textually close to a glitch-soc-only dependency. Updated the dependency like upstream did.
Diffstat (limited to 'config/application.rb')
-rw-r--r-- | config/application.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/config/application.rb b/config/application.rb index c51eacd68..43631c551 100644 --- a/config/application.rb +++ b/config/application.rb @@ -35,6 +35,7 @@ require_relative '../lib/terrapin/multi_pipe_extensions' require_relative '../lib/mastodon/snowflake' require_relative '../lib/mastodon/version' require_relative '../lib/mastodon/rack_middleware' +require_relative '../lib/public_file_server_middleware' require_relative '../lib/devise/two_factor_ldap_authenticatable' require_relative '../lib/devise/two_factor_pam_authenticatable' require_relative '../lib/chewy/strategy/mastodon' @@ -181,6 +182,10 @@ module Mastodon config.active_job.queue_adapter = :sidekiq config.action_mailer.deliver_later_queue_name = 'mailers' + # We use our own middleware for this + config.public_file_server.enabled = false + + config.middleware.use PublicFileServerMiddleware if Rails.env.development? || ENV['RAILS_SERVE_STATIC_FILES'] == 'true' config.middleware.use Rack::Attack config.middleware.use Mastodon::RackMiddleware |