Commit 91c70c5b1c60160253520a5ac6ac3eec46faf416

Authored by Jacob Vosmaer
1 parent 5d6e4bd2

Use gitlab_shell.path to invoke rewrite-hooks.sh

The backup restore code for repositories was assuming that gitlab-shell
is installed in /home/git/gitlab-shell. This commit changes that to use
the configuration setting from gitlab.yml that specifies the path where
gitlab-shell is installed.
Showing 1 changed file with 1 additions and 2 deletions   Show diff stats
lib/backup/repository.rb
... ... @@ -72,8 +72,7 @@ module Backup
72 72 end
73 73  
74 74 print 'Put GitLab hooks in repositories dirs'.yellow
75   - gitlab_shell_user_home = File.expand_path("~#{Gitlab.config.gitlab_shell.ssh_user}")
76   - if system("#{gitlab_shell_user_home}/gitlab-shell/support/rewrite-hooks.sh", Gitlab.config.gitlab_shell.repos_path)
  75 + if system("#{Gitlab.config.gitlab_shell.path}/support/rewrite-hooks.sh", Gitlab.config.gitlab_shell.repos_path)
77 76 puts " [DONE]".green
78 77 else
79 78 puts " [FAILED]".red
... ...