Fix bug.
This commit is contained in:
parent
225103082a
commit
6e0cf64481
|
@ -22,13 +22,13 @@ namespace :exec_commands do
|
|||
@command_trans = {}
|
||||
@command_relations = {"upgrade_site"=>'git fetch origin && rails runner "a=Admin::SitesController.new;a.git_reset(%w(origin)[0],%w(update)[0]);while(1) do (Multithread.where(key: %w(update_manager)[0],status: %w(finish)[0]).count!=0 ? break : nil) end;sleep(5)"',
|
||||
"bundle_update"=>"bundle update && kill -s USR2 `cat tmp/pids/unicorn.pid`",
|
||||
"restart_site"=>"kill -s TERM `fuser tmp/pids/unicorn.sock tmp/sockets/unicorn.sock tmp/unicorn.sock` && bundle exec unicorn_rails -c config/unicorn.rb -D -E {{rails_env}}"}
|
||||
"restart_site"=>"kill -s TERM `fuser tmp/pids/unicorn.sock tmp/sockets/unicorn.sock tmp/unicorn.sock`;bundle exec unicorn_rails -c config/unicorn.rb -D -E {{rails_env}}"}
|
||||
@command_relations.each do |k,v|
|
||||
@command_trans[k] = I18n.t("client_management.#{k}")
|
||||
end
|
||||
rails_envs = ["production", "development"]
|
||||
rails_envs.each do |env|
|
||||
@command_relations["start_site_in_env,#{env}"] = "kill -s TERM `fuser tmp/pids/unicorn.sock tmp/sockets/unicorn.sock tmp/unicorn.sock` && bundle exec unicorn_rails -c config/unicorn.rb -D -E #{env}"
|
||||
@command_relations["start_site_in_env,#{env}"] = "kill -s TERM `fuser tmp/pids/unicorn.sock tmp/sockets/unicorn.sock tmp/unicorn.sock`;bundle exec unicorn_rails -c config/unicorn.rb -D -E #{env}"
|
||||
@command_trans["start_site_in_env,#{env}"] = I18n.t("client_management.start_site_in_env",{:env=>env})
|
||||
end
|
||||
begin
|
||||
|
|
Loading…
Reference in New Issue