summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorGrzegorz Bizon <grzegorz@gitlab.com>2018-05-28 08:13:58 +0000
committerGrzegorz Bizon <grzegorz@gitlab.com>2018-05-28 08:13:58 +0000
commitcfdd80ec10c669a6f6811aef02b0df233a709881 (patch)
treec633badf70718b8ac4fc8be3e78a2172568be4d0 /lib
parentbee339ad10fc4d4bd94a406eb0d24d7759d73972 (diff)
parent8fad07383ada021fc995294fd0fe0f77fe37da35 (diff)
downloadgitlab-ce-cfdd80ec10c669a6f6811aef02b0df233a709881.tar.gz
Merge branch 'zj-internal-repo-path' into 'master'
Don't pass the repository path to Gitlab Shell See merge request gitlab-org/gitlab-ce!19011
Diffstat (limited to 'lib')
-rw-r--r--lib/api/helpers/internal_helpers.rb6
-rw-r--r--lib/api/internal.rb6
2 files changed, 5 insertions, 7 deletions
diff --git a/lib/api/helpers/internal_helpers.rb b/lib/api/helpers/internal_helpers.rb
index abe3d353984..83151be82ad 100644
--- a/lib/api/helpers/internal_helpers.rb
+++ b/lib/api/helpers/internal_helpers.rb
@@ -89,12 +89,6 @@ module API
end
end
- # Return the repository full path so that gitlab-shell has it when
- # handling ssh commands
- def repository_path
- repository.path_to_repo
- end
-
# Return the Gitaly Address if it is enabled
def gitaly_payload(action)
return unless %w[git-receive-pack git-upload-pack git-upload-archive].include?(action)
diff --git a/lib/api/internal.rb b/lib/api/internal.rb
index a3dac36b8b6..a9803be9f69 100644
--- a/lib/api/internal.rb
+++ b/lib/api/internal.rb
@@ -59,7 +59,11 @@ module API
status: true,
gl_repository: gl_repository,
gl_username: user&.username,
- repository_path: repository_path,
+
+ # This repository_path is a bogus value but gitlab-shell still requires
+ # its presence. https://gitlab.com/gitlab-org/gitlab-shell/issues/135
+ repository_path: '/',
+
gitaly: gitaly_payload(params[:action])
}
end