diff --git a/config/application.rb b/config/application.rb index acc2d5017..ffba6ba0c 100644 --- a/config/application.rb +++ b/config/application.rb @@ -167,3 +167,11 @@ module Discourse end end + +if defined?(PhusionPassenger) + PhusionPassenger.on_event(:starting_worker_process) do |forked| + if forked + Discourse.after_fork + end + end +end