summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2013-10-04 11:24:27 +0000
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2013-10-04 11:24:27 +0000
commitd3450ad2be3d8f7ee445b11a97f6eca77e504b2f (patch)
tree7062baaea9adbda593cd14967ffe8b934f0817fb
parent0223597acaa3e0e03654b0c6b255601c35ed7261 (diff)
parent4017789f5aac8a8244e80c3f4feada5393c8a4ed (diff)
downloadgitlab-ce-d3450ad2be3d8f7ee445b11a97f6eca77e504b2f.tar.gz
Merge branch 'improve_sidekiq_check' of /home/git/repositories/gitlab/gitlabhq
-rw-r--r--lib/tasks/gitlab/check.rake10
1 files changed, 6 insertions, 4 deletions
diff --git a/lib/tasks/gitlab/check.rake b/lib/tasks/gitlab/check.rake
index 6e2a59f62ac..531b01c4dd5 100644
--- a/lib/tasks/gitlab/check.rake
+++ b/lib/tasks/gitlab/check.rake
@@ -289,7 +289,6 @@ namespace :gitlab do
########################
def check_gitlab_git_config
- gitlab_user = Gitlab.config.gitlab.user
print "Git configured for #{gitlab_user} user? ... "
options = {
@@ -664,8 +663,8 @@ namespace :gitlab do
puts "#{sidekiq_match.length}".red
try_fixing_it(
'sudo service gitlab stop',
- 'sudo pkill -f sidekiq',
- 'sleep 10 && sudo pkill -9 -f sidekiq',
+ "sudo pkill -u #{gitlab_user} -f sidekiq",
+ "sleep 10 && sudo pkill -9 -u #{gitlab_user} -f sidekiq",
'sudo service gitlab start'
)
fix_and_rerun
@@ -709,10 +708,13 @@ namespace :gitlab do
end
def sudo_gitlab(command)
- gitlab_user = Gitlab.config.gitlab.user
"sudo -u #{gitlab_user} -H #{command}"
end
+ def gitlab_user
+ Gitlab.config.gitlab.user
+ end
+
def start_checking(component)
puts "Checking #{component.yellow} ..."
puts ""