Files
ubicloud/puma_config.rb
Jeremy Evans 4805464c4b Disable the use of HTTP 1.1 keep alives in Puma
Fixes issues in Puma when used with Heroku Router 2.0. See
https://www.heroku.com/blog/pumas-routers-keepalives-ohmy/
2025-07-23 01:58:50 +09:00

18 lines
313 B
Ruby

# frozen_string_literal: true
# :nocov:
environment ENV["RACK_ENV"] || "development"
port ENV["PORT"] || "3000"
threads 15, 15
enable_keep_alives false
if @config.options[:workers] > 0
silence_single_worker_warning
preload_app!
before_fork do
Sequel::DATABASES.each(&:disconnect)
end
end
# :nocov: