Revert "move unicorn into the heroku group till we decide if we switch completly to it or not"
This reverts commit641cedf343. Revert "Merge pull request #2663 from torrancew/with_unicorn" This reverts commit2a2efd097f, reversing changes made to78978f051e.
This commit is contained in:
parent
177f608276
commit
f2cc8b4e41
4 changed files with 2 additions and 55 deletions
1
Gemfile
1
Gemfile
|
|
@ -38,7 +38,6 @@ end
|
||||||
|
|
||||||
group :heroku do
|
group :heroku do
|
||||||
gem 'pg'
|
gem 'pg'
|
||||||
gem 'unicorn', '~> 4.1.1', :require => false
|
|
||||||
end
|
end
|
||||||
|
|
||||||
gem 'settingslogic', :git => 'git://github.com/binarylogic/settingslogic.git'
|
gem 'settingslogic', :git => 'git://github.com/binarylogic/settingslogic.git'
|
||||||
|
|
|
||||||
|
|
@ -218,7 +218,6 @@ GEM
|
||||||
multi_json
|
multi_json
|
||||||
jwt (0.1.4)
|
jwt (0.1.4)
|
||||||
json (>= 1.2.4)
|
json (>= 1.2.4)
|
||||||
kgio (2.7.0)
|
|
||||||
launchy (2.0.3)
|
launchy (2.0.3)
|
||||||
linecache (0.46)
|
linecache (0.46)
|
||||||
rbx-require-relative (> 0.0.4)
|
rbx-require-relative (> 0.0.4)
|
||||||
|
|
@ -308,7 +307,6 @@ GEM
|
||||||
rake (>= 0.8.7)
|
rake (>= 0.8.7)
|
||||||
rdoc (~> 3.4)
|
rdoc (~> 3.4)
|
||||||
thor (~> 0.14.4)
|
thor (~> 0.14.4)
|
||||||
raindrops (0.8.0)
|
|
||||||
rake (0.9.2.2)
|
rake (0.9.2.2)
|
||||||
rbx-require-relative (0.0.5)
|
rbx-require-relative (0.0.5)
|
||||||
rdoc (3.12)
|
rdoc (3.12)
|
||||||
|
|
@ -393,10 +391,6 @@ GEM
|
||||||
typhoeus (0.3.3)
|
typhoeus (0.3.3)
|
||||||
mime-types
|
mime-types
|
||||||
tzinfo (0.3.31)
|
tzinfo (0.3.31)
|
||||||
unicorn (4.1.1)
|
|
||||||
kgio (~> 2.4)
|
|
||||||
rack
|
|
||||||
raindrops (~> 0.6)
|
|
||||||
vegas (0.1.8)
|
vegas (0.1.8)
|
||||||
rack (>= 1.0.0)
|
rack (>= 1.0.0)
|
||||||
warden (1.0.6)
|
warden (1.0.6)
|
||||||
|
|
@ -496,7 +490,6 @@ DEPENDENCIES
|
||||||
timecop
|
timecop
|
||||||
twitter (= 2.0.2)
|
twitter (= 2.0.2)
|
||||||
typhoeus
|
typhoeus
|
||||||
unicorn (~> 4.1.1)
|
|
||||||
vanna!
|
vanna!
|
||||||
webmock
|
webmock
|
||||||
whenever
|
whenever
|
||||||
|
|
|
||||||
2
Procfile
2
Procfile
|
|
@ -1,3 +1,3 @@
|
||||||
web: bundle exec unicorn -c config/unicorn.rb -p $PORT
|
web: bundle exec rails s thin -p $PORT
|
||||||
redis: redis-server
|
redis: redis-server
|
||||||
worker: QUEUE=* bundle exec rake resque:work
|
worker: QUEUE=* bundle exec rake resque:work
|
||||||
|
|
|
||||||
|
|
@ -1,45 +0,0 @@
|
||||||
rails_env = ENV['RAILS_ENV'] || 'development'
|
|
||||||
|
|
||||||
# Enable and set these to run the worker as a different user/group
|
|
||||||
#user = 'diaspora'
|
|
||||||
#group = 'diaspora'
|
|
||||||
|
|
||||||
worker_processes 3
|
|
||||||
|
|
||||||
## Load the app before spawning workers
|
|
||||||
#preload_app true
|
|
||||||
|
|
||||||
# How long to wait before killing an unresponsive worker
|
|
||||||
timeout 30
|
|
||||||
|
|
||||||
#pid '/var/run/diaspora/diaspora.pid'
|
|
||||||
#listen '/var/run/diaspora/diaspora.sock', :backlog => 2048
|
|
||||||
|
|
||||||
# Ruby Enterprise Feature
|
|
||||||
if GC.respond_to?(:copy_on_write_friendly=)
|
|
||||||
GC.copy_on_write_friendly = true
|
|
||||||
end
|
|
||||||
|
|
||||||
|
|
||||||
before_fork do |server, worker|
|
|
||||||
# If using preload_app, enable this line
|
|
||||||
#ActiveRecord::Base.disconnect!
|
|
||||||
|
|
||||||
old_pid = '/var/run/diaspora/diaspora.pid.oldbin'
|
|
||||||
if File.exists?(old_pid) && server.pid != old_pid
|
|
||||||
begin
|
|
||||||
Process.kill("QUIT", File.read(old_pid).to_i)
|
|
||||||
rescue Errno::ENOENT, Errno::ESRCH
|
|
||||||
# someone else did our job for us
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
|
|
||||||
after_fork do |server, worker|
|
|
||||||
# If using preload_app, enable this line
|
|
||||||
#ActiveRecord::Base.establish_connection
|
|
||||||
|
|
||||||
# Enable this line to have the workers run as different user/group
|
|
||||||
#worker.user(user, group)
|
|
||||||
end
|
|
||||||
Loading…
Reference in a new issue