diff options
author | Bob Van Landuyt <bob@vanlanduyt.co> | 2018-11-21 20:29:18 +0300 |
---|---|---|
committer | Bob Van Landuyt <bob@vanlanduyt.co> | 2018-11-26 18:44:26 +0300 |
commit | 67f2faa72d53096bf71cbe126b5b6d0830d42886 (patch) | |
tree | e31e7486e5da779542a3346dedff3134b0c44f55 /lib/gitlab/git | |
parent | 5e9921d547501fc8be2ebd16b63eec712154db10 (diff) |
Don't specify `shell` for Gitaly write-ref
Use shelling out to git to write refs instead of rugged, hoping to
avoid creating invalid refs.
To update HEAD we switched to using `git symbolic-ref`.
Diffstat (limited to 'lib/gitlab/git')
-rw-r--r-- | lib/gitlab/git/repository.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/gitlab/git/repository.rb b/lib/gitlab/git/repository.rb index 9b48031b2d3..0a541031884 100644 --- a/lib/gitlab/git/repository.rb +++ b/lib/gitlab/git/repository.rb @@ -723,11 +723,11 @@ module Gitlab delete_refs(tmp_ref) end - def write_ref(ref_path, ref, old_ref: nil, shell: true) + def write_ref(ref_path, ref, old_ref: nil) ref_path = "#{Gitlab::Git::BRANCH_REF_PREFIX}#{ref_path}" unless ref_path.start_with?("refs/") || ref_path == "HEAD" wrapped_gitaly_errors do - gitaly_repository_client.write_ref(ref_path, ref, old_ref, shell) + gitaly_repository_client.write_ref(ref_path, ref, old_ref) end end |