Use 4 unicorn worker processes instead of 3
This commit is contained in:
parent
3978af31c6
commit
f0ac30f0a6
|
@ -1,15 +1,15 @@
|
||||||
worker_processes 3
|
worker_processes 4
|
||||||
timeout 30
|
timeout 30
|
||||||
preload_app true
|
preload_app true
|
||||||
|
|
||||||
before_fork do
|
before_fork do |_server, _worker|
|
||||||
Signal.trap 'TERM' do
|
Signal.trap 'TERM' do
|
||||||
Process.kill 'QUIT', Process.pid
|
Process.kill 'QUIT', Process.pid
|
||||||
end
|
end
|
||||||
ActiveRecord::Base.connection.disconnect!
|
ActiveRecord::Base.connection.disconnect!
|
||||||
end
|
end
|
||||||
|
|
||||||
after_fork do
|
after_fork do |_server, _worker|
|
||||||
Signal.trap 'TERM' do
|
Signal.trap 'TERM' do
|
||||||
end
|
end
|
||||||
ActiveRecord::Base.establish_connection
|
ActiveRecord::Base.establish_connection
|
||||||
|
|
Loading…
Reference in New Issue