]> cat aescling's git repositories - mastodon.git/commitdiff
Disable host check on healthcheck path (#16243)
authorJeong Arm <kjwonmail@gmail.com>
Sun, 16 May 2021 17:48:59 +0000 (02:48 +0900)
committerGitHub <noreply@github.com>
Sun, 16 May 2021 17:48:59 +0000 (19:48 +0200)
config/initializers/1_hosts.rb

index eaf6e01815ae158405931a1f5bc9a4de598320bd..f470fddb3684f443f958eb8e1f47f6683738bc24 100644 (file)
@@ -31,5 +31,6 @@ Rails.application.configure do
     config.hosts << host if host.present?
     config.hosts << web_host if web_host.present?
     config.hosts.concat(alternate_domains) if alternate_domains.present?
+    config.hosts_authorization = { exclude: ->(request) { request.path == '/health' } }
   end
 end