Skip to content
Snippets Groups Projects
Commit 1822c7d4 authored by Jacob Vosmaer (GitLab)'s avatar Jacob Vosmaer (GitLab) Committed by Wes Gurney
Browse files

Only kill sidekiqs belonging to gitlab user

parent bf2a2d89
No related branches found
No related tags found
1 merge request!4954Add support to configure webhook_timeout in gitlab.yaml
This commit is part of merge request !4954. Comments created here will be created in the context of that merge request.
Loading
Loading
@@ -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 = {
Loading
Loading
@@ -646,8 +645,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
Loading
Loading
@@ -691,10 +690,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 ""
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment