diff options
author | Ash McKenzie <amckenzie@gitlab.com> | 2018-07-25 13:37:51 +1000 |
---|---|---|
committer | Ash McKenzie <amckenzie@gitlab.com> | 2018-07-25 22:01:14 +1000 |
commit | aadf5355479f560b3abe1cec6c8cde50a1e5bdeb (patch) | |
tree | 6aa6139adf5c1191d7f7b10996a563ee1f6618a7 /lib/gitlab_shell.rb | |
parent | 319794918a90da5e68b4858c7fc29eff704b0c96 (diff) | |
download | gitlab-shell-aadf5355479f560b3abe1cec6c8cde50a1e5bdeb.tar.gz |
Move GL_PROTOCOL into GitlabNet
Diffstat (limited to 'lib/gitlab_shell.rb')
-rw-r--r-- | lib/gitlab_shell.rb | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/gitlab_shell.rb b/lib/gitlab_shell.rb index cd6fcb9..f6426b3 100644 --- a/lib/gitlab_shell.rb +++ b/lib/gitlab_shell.rb @@ -23,7 +23,6 @@ class GitlabShell # rubocop:disable Metrics/ClassLength 'git-receive-pack' => File.join(ROOT_PATH, 'bin', 'gitaly-receive-pack') }.freeze API_COMMANDS = %w(2fa_recovery_codes).freeze - GL_PROTOCOL = 'ssh'.freeze def initialize(key_id) @key_id = key_id @@ -106,7 +105,7 @@ class GitlabShell # rubocop:disable Metrics/ClassLength end def verify_access - status = api.check_access(git_access, nil, repo_name, key_id, '_any', GL_PROTOCOL) + status = api.check_access(git_access, nil, repo_name, key_id, '_any', GitlabNet::GL_PROTOCOL) raise AccessDeniedError, status.message unless status.allowed? @@ -167,7 +166,7 @@ class GitlabShell # rubocop:disable Metrics/ClassLength 'LD_LIBRARY_PATH' => ENV['LD_LIBRARY_PATH'], 'LANG' => ENV['LANG'], 'GL_ID' => key_id, - 'GL_PROTOCOL' => GL_PROTOCOL, + 'GL_PROTOCOL' => GitlabNet::GL_PROTOCOL, 'GL_REPOSITORY' => @gl_repository, 'GL_USERNAME' => username } |