diff options
author | Małgorzata Ksionek <mksionek@gitlab.com> | 2019-10-01 16:40:19 +0200 |
---|---|---|
committer | Małgorzata Ksionek <mksionek@gitlab.com> | 2019-10-01 16:40:19 +0200 |
commit | eff3b3c0e48e9ffc213108965f16e96f10bcda3e (patch) | |
tree | 072d978160ef4de46a51cdfd3421f35e0ea661ae | |
parent | 1ba172d426274832f4a76a1b540dce462ec932f3 (diff) | |
download | gitlab-shell-eff3b3c0e48e9ffc213108965f16e96f10bcda3e.tar.gz |
Reverse ruby changes
24 files changed, 24 insertions, 24 deletions
diff --git a/lib/gitlab_net.rb b/lib/gitlab_net.rb index 75062a6..09767da 100644 --- a/lib/gitlab_net.rb +++ b/lib/gitlab_net.rb @@ -28,7 +28,7 @@ class GitlabNet # rubocop:disable Metrics/ClassLength who_sym, _, who_v = self.class.parse_who(who) params[who_sym] = who_v - url = "#{internal_api_endpoint}/allowed/secure" + url = "#{internal_api_endpoint}/allowed" resp = post(url, params) case resp diff --git a/spec/gitlab_shell_custom_git_receive_pack_spec.rb b/spec/gitlab_shell_custom_git_receive_pack_spec.rb index 755aac8..95cd8ea 100644 --- a/spec/gitlab_shell_custom_git_receive_pack_spec.rb +++ b/spec/gitlab_shell_custom_git_receive_pack_spec.rb @@ -24,7 +24,7 @@ describe 'Custom bin/gitlab-shell git-receive-pack' do res.body = {"result" => output}.to_json end - server.mount_proc('/api/v4/internal/allowed/secure') do |req, res| + server.mount_proc('/api/v4/internal/allowed') do |req, res| res.content_type = 'application/json' key_id = req.query['key_id'] || req.query['username'] diff --git a/spec/gitlab_shell_lfs_authentication_spec.rb b/spec/gitlab_shell_lfs_authentication_spec.rb index d23ec51..7cdb320 100644 --- a/spec/gitlab_shell_lfs_authentication_spec.rb +++ b/spec/gitlab_shell_lfs_authentication_spec.rb @@ -26,7 +26,7 @@ describe 'bin/gitlab-shell git-lfs-authentication' do end end - server.mount_proc('/api/v4/internal/allowed/secure') do |req, res| + server.mount_proc('/api/v4/internal/allowed') do |req, res| res.content_type = 'application/json' key_id = req.query['key_id'] || req.query['username'] diff --git a/spec/vcr_cassettes/allowed-pull.yml b/spec/vcr_cassettes/allowed-pull.yml index 4c6f64a..25c263f 100644 --- a/spec/vcr_cassettes/allowed-pull.yml +++ b/spec/vcr_cassettes/allowed-pull.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: post - uri: http://localhost:3000/api/v4/internal/allowed/secure + uri: http://localhost:3000/api/v4/internal/allowed body: encoding: US-ASCII string: action=git-upload-pack&changes=0000000000000000000000000000000000000000+92d0970eefd7acb6d548878925ce2208cfe2d2ec+refs%2Fheads%2Fbranch4&gl_repository&project=gitlab-org%2Fgitlab-test.git&protocol=ssh&env=%7B%7D&key_id=1&secret_token=0a3938d9d95d807e94d937af3a4fbbea%0A diff --git a/spec/vcr_cassettes/allowed-push-project-not-found-404-text-html.yml b/spec/vcr_cassettes/allowed-push-project-not-found-404-text-html.yml index dc7744e..4adb088 100644 --- a/spec/vcr_cassettes/allowed-push-project-not-found-404-text-html.yml +++ b/spec/vcr_cassettes/allowed-push-project-not-found-404-text-html.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: post - uri: http://localhost:3000/api/v4/internal/allowed/secure + uri: http://localhost:3000/api/v4/internal/allowed body: encoding: US-ASCII string: action=git-receive-pack&changes=0000000000000000000000000000000000000000+92d0970eefd7acb6d548878925ce2208cfe2d2ec+refs%2Fheads%2Fbranch4&gl_repository&project=gitlab-org%2Fgitlab-test.git&protocol=ssh&env=%7B%7D&key_id=1&secret_token=0a3938d9d95d807e94d937af3a4fbbea%0A diff --git a/spec/vcr_cassettes/allowed-push-project-not-found-404-text-plain.yml b/spec/vcr_cassettes/allowed-push-project-not-found-404-text-plain.yml index 13f061b..a84b7d2 100644 --- a/spec/vcr_cassettes/allowed-push-project-not-found-404-text-plain.yml +++ b/spec/vcr_cassettes/allowed-push-project-not-found-404-text-plain.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: post - uri: http://localhost:3000/api/v4/internal/allowed/secure + uri: http://localhost:3000/api/v4/internal/allowed body: encoding: US-ASCII string: action=git-receive-pack&changes=0000000000000000000000000000000000000000+92d0970eefd7acb6d548878925ce2208cfe2d2ec+refs%2Fheads%2Fbranch4&gl_repository&project=gitlab-org%2Fgitlab-test.git&protocol=ssh&env=%7B%7D&key_id=1&secret_token=0a3938d9d95d807e94d937af3a4fbbea%0A diff --git a/spec/vcr_cassettes/allowed-push-project-not-found-404.yml b/spec/vcr_cassettes/allowed-push-project-not-found-404.yml index 1ae63b4..e531fcb 100644 --- a/spec/vcr_cassettes/allowed-push-project-not-found-404.yml +++ b/spec/vcr_cassettes/allowed-push-project-not-found-404.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: post - uri: http://localhost:3000/api/v4/internal/allowed/secure + uri: http://localhost:3000/api/v4/internal/allowed body: encoding: US-ASCII string: action=git-receive-pack&changes=0000000000000000000000000000000000000000+92d0970eefd7acb6d548878925ce2208cfe2d2ec+refs%2Fheads%2Fbranch4&gl_repository&project=gitlab-org%2Fgitlab-test.git&protocol=ssh&env=%7B%7D&key_id=1&secret_token=0a3938d9d95d807e94d937af3a4fbbea%0A diff --git a/spec/vcr_cassettes/allowed-push-project-not-found-text-html.yml b/spec/vcr_cassettes/allowed-push-project-not-found-text-html.yml index a9e99de..b2738fe 100644 --- a/spec/vcr_cassettes/allowed-push-project-not-found-text-html.yml +++ b/spec/vcr_cassettes/allowed-push-project-not-found-text-html.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: post - uri: http://localhost:3000/api/v4/internal/allowed/secure + uri: http://localhost:3000/api/v4/internal/allowed body: encoding: US-ASCII string: action=git-receive-pack&changes=0000000000000000000000000000000000000000+92d0970eefd7acb6d548878925ce2208cfe2d2ec+refs%2Fheads%2Fbranch4&gl_repository&project=gitlab-org%2Fgitlab-test.git&protocol=ssh&env=%7B%7D&key_id=1&secret_token=0a3938d9d95d807e94d937af3a4fbbea%0A diff --git a/spec/vcr_cassettes/allowed-push-project-not-found-text-plain.yml b/spec/vcr_cassettes/allowed-push-project-not-found-text-plain.yml index b21aee3..34532ce 100644 --- a/spec/vcr_cassettes/allowed-push-project-not-found-text-plain.yml +++ b/spec/vcr_cassettes/allowed-push-project-not-found-text-plain.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: post - uri: http://localhost:3000/api/v4/internal/allowed/secure + uri: http://localhost:3000/api/v4/internal/allowed body: encoding: US-ASCII string: action=git-receive-pack&changes=0000000000000000000000000000000000000000+92d0970eefd7acb6d548878925ce2208cfe2d2ec+refs%2Fheads%2Fbranch4&gl_repository&project=gitlab-org%2Fgitlab-test.git&protocol=ssh&env=%7B%7D&key_id=1&secret_token=0a3938d9d95d807e94d937af3a4fbbea%0A diff --git a/spec/vcr_cassettes/allowed-push-project-not-found.yml b/spec/vcr_cassettes/allowed-push-project-not-found.yml index 6a74445..f25fa7e 100644 --- a/spec/vcr_cassettes/allowed-push-project-not-found.yml +++ b/spec/vcr_cassettes/allowed-push-project-not-found.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: post - uri: http://localhost:3000/api/v4/internal/allowed/secure + uri: http://localhost:3000/api/v4/internal/allowed body: encoding: US-ASCII string: action=git-receive-pack&changes=0000000000000000000000000000000000000000+92d0970eefd7acb6d548878925ce2208cfe2d2ec+refs%2Fheads%2Fbranch4&gl_repository&project=gitlab-org%2Fgitlab-test.git&protocol=ssh&env=%7B%7D&key_id=1&secret_token=0a3938d9d95d807e94d937af3a4fbbea%0A diff --git a/spec/vcr_cassettes/allowed-push.yml b/spec/vcr_cassettes/allowed-push.yml index 22e5e66..e61c140 100644 --- a/spec/vcr_cassettes/allowed-push.yml +++ b/spec/vcr_cassettes/allowed-push.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: post - uri: http://localhost:3000/api/v4/internal/allowed/secure + uri: http://localhost:3000/api/v4/internal/allowed body: encoding: US-ASCII string: action=git-receive-pack&changes=0000000000000000000000000000000000000000+92d0970eefd7acb6d548878925ce2208cfe2d2ec+refs%2Fheads%2Fbranch4&gl_repository&project=gitlab-org%2Fgitlab-test.git&protocol=ssh&env=%7B%7D&key_id=1&secret_token=0a3938d9d95d807e94d937af3a4fbbea%0A diff --git a/spec/vcr_cassettes/http-pull-disabled.yml b/spec/vcr_cassettes/http-pull-disabled.yml index 6f2aa1f..abae549 100644 --- a/spec/vcr_cassettes/http-pull-disabled.yml +++ b/spec/vcr_cassettes/http-pull-disabled.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: post - uri: http://localhost:3000/api/v4/internal/allowed/secure + uri: http://localhost:3000/api/v4/internal/allowed body: encoding: US-ASCII string: action=git-upload-pack&changes=0000000000000000000000000000000000000000+92d0970eefd7acb6d548878925ce2208cfe2d2ec+refs%2Fheads%2Fbranch4&gl_repository&project=gitlab-org%2Fgitlab-test.git&protocol=http&env=%7B%7D&key_id=1&secret_token=0a3938d9d95d807e94d937af3a4fbbea%0A diff --git a/spec/vcr_cassettes/http-push-disabled.yml b/spec/vcr_cassettes/http-push-disabled.yml index e488634..429fc32 100644 --- a/spec/vcr_cassettes/http-push-disabled.yml +++ b/spec/vcr_cassettes/http-push-disabled.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: post - uri: http://localhost:3000/api/v4/internal/allowed/secure + uri: http://localhost:3000/api/v4/internal/allowed body: encoding: US-ASCII string: action=git-receive-pack&changes=0000000000000000000000000000000000000000+92d0970eefd7acb6d548878925ce2208cfe2d2ec+refs%2Fheads%2Fbranch4&gl_repository&project=gitlab-org%2Fgitlab-test.git&protocol=http&env=%7B%7D&key_id=1&secret_token=0a3938d9d95d807e94d937af3a4fbbea%0A diff --git a/spec/vcr_cassettes/ssh-pull-disabled.yml b/spec/vcr_cassettes/ssh-pull-disabled.yml index f6717e4..54ae895 100644 --- a/spec/vcr_cassettes/ssh-pull-disabled.yml +++ b/spec/vcr_cassettes/ssh-pull-disabled.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: post - uri: http://localhost:3000/api/v4/internal/allowed/secure + uri: http://localhost:3000/api/v4/internal/allowed body: encoding: US-ASCII string: action=git-upload-pack&changes=0000000000000000000000000000000000000000+92d0970eefd7acb6d548878925ce2208cfe2d2ec+refs%2Fheads%2Fbranch4&gl_repository&project=gitlab-org%2Fgitlab-test.git&protocol=ssh&env=%7B%7D&key_id=1&secret_token=0a3938d9d95d807e94d937af3a4fbbea%0A diff --git a/spec/vcr_cassettes/ssh-pull-project-denied-401-text-html.yml b/spec/vcr_cassettes/ssh-pull-project-denied-401-text-html.yml index fb43ce8..d334108 100644 --- a/spec/vcr_cassettes/ssh-pull-project-denied-401-text-html.yml +++ b/spec/vcr_cassettes/ssh-pull-project-denied-401-text-html.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: post - uri: http://localhost:3000/api/v4/internal/allowed/secure + uri: http://localhost:3000/api/v4/internal/allowed body: encoding: US-ASCII string: action=git-upload-pack&changes=0000000000000000000000000000000000000000+92d0970eefd7acb6d548878925ce2208cfe2d2ec+refs%2Fheads%2Fbranch4&gl_repository&project=gitlab-org%2Fgitlab-test.git&protocol=ssh&env=%7B%7D&key_id=2&secret_token=0a3938d9d95d807e94d937af3a4fbbea%0A diff --git a/spec/vcr_cassettes/ssh-pull-project-denied-401-text-plain.yml b/spec/vcr_cassettes/ssh-pull-project-denied-401-text-plain.yml index c44b87a..e072493 100644 --- a/spec/vcr_cassettes/ssh-pull-project-denied-401-text-plain.yml +++ b/spec/vcr_cassettes/ssh-pull-project-denied-401-text-plain.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: post - uri: http://localhost:3000/api/v4/internal/allowed/secure + uri: http://localhost:3000/api/v4/internal/allowed body: encoding: US-ASCII string: action=git-upload-pack&changes=0000000000000000000000000000000000000000+92d0970eefd7acb6d548878925ce2208cfe2d2ec+refs%2Fheads%2Fbranch4&gl_repository&project=gitlab-org%2Fgitlab-test.git&protocol=ssh&env=%7B%7D&key_id=2&secret_token=0a3938d9d95d807e94d937af3a4fbbea%0A diff --git a/spec/vcr_cassettes/ssh-pull-project-denied-401.yml b/spec/vcr_cassettes/ssh-pull-project-denied-401.yml index 0a48da0..4a9305a 100644 --- a/spec/vcr_cassettes/ssh-pull-project-denied-401.yml +++ b/spec/vcr_cassettes/ssh-pull-project-denied-401.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: post - uri: http://localhost:3000/api/v4/internal/allowed/secure + uri: http://localhost:3000/api/v4/internal/allowed body: encoding: US-ASCII string: action=git-upload-pack&changes=0000000000000000000000000000000000000000+92d0970eefd7acb6d548878925ce2208cfe2d2ec+refs%2Fheads%2Fbranch4&gl_repository&project=gitlab-org%2Fgitlab-test.git&protocol=ssh&env=%7B%7D&key_id=2&secret_token=0a3938d9d95d807e94d937af3a4fbbea%0A diff --git a/spec/vcr_cassettes/ssh-pull-project-denied-with-user.yml b/spec/vcr_cassettes/ssh-pull-project-denied-with-user.yml index 8cd91a6..35a2c11 100644 --- a/spec/vcr_cassettes/ssh-pull-project-denied-with-user.yml +++ b/spec/vcr_cassettes/ssh-pull-project-denied-with-user.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: post - uri: http://localhost:3000/api/v4/internal/allowed/secure + uri: http://localhost:3000/api/v4/internal/allowed body: encoding: US-ASCII string: action=git-upload-pack&changes=0000000000000000000000000000000000000000+92d0970eefd7acb6d548878925ce2208cfe2d2ec+refs%2Fheads%2Fbranch4&gl_repository&project=gitlab-org%2Fgitlab-test.git&protocol=ssh&env=%7B%7D&user_id=2&secret_token=0a3938d9d95d807e94d937af3a4fbbea%0A diff --git a/spec/vcr_cassettes/ssh-pull-project-denied.yml b/spec/vcr_cassettes/ssh-pull-project-denied.yml index f8c7b87..9c99a17 100644 --- a/spec/vcr_cassettes/ssh-pull-project-denied.yml +++ b/spec/vcr_cassettes/ssh-pull-project-denied.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: post - uri: http://localhost:3000/api/v4/internal/allowed/secure + uri: http://localhost:3000/api/v4/internal/allowed body: encoding: US-ASCII string: action=git-upload-pack&changes=0000000000000000000000000000000000000000+92d0970eefd7acb6d548878925ce2208cfe2d2ec+refs%2Fheads%2Fbranch4&gl_repository&project=gitlab-org%2Fgitlab-test.git&protocol=ssh&env=%7B%7D&key_id=2&secret_token=0a3938d9d95d807e94d937af3a4fbbea%0A diff --git a/spec/vcr_cassettes/ssh-push-disabled.yml b/spec/vcr_cassettes/ssh-push-disabled.yml index fc09f55..7795e52 100644 --- a/spec/vcr_cassettes/ssh-push-disabled.yml +++ b/spec/vcr_cassettes/ssh-push-disabled.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: post - uri: http://localhost:3000/api/v4/internal/allowed/secure + uri: http://localhost:3000/api/v4/internal/allowed body: encoding: US-ASCII string: action=git-receive-pack&changes=0000000000000000000000000000000000000000+92d0970eefd7acb6d548878925ce2208cfe2d2ec+refs%2Fheads%2Fbranch4&gl_repository&project=gitlab-org%2Fgitlab-test.git&protocol=ssh&env=%7B%7D&key_id=1&secret_token=0a3938d9d95d807e94d937af3a4fbbea%0A diff --git a/spec/vcr_cassettes/ssh-push-project-denied-401-text-html.yml b/spec/vcr_cassettes/ssh-push-project-denied-401-text-html.yml index 02ea6d9..08dea91 100644 --- a/spec/vcr_cassettes/ssh-push-project-denied-401-text-html.yml +++ b/spec/vcr_cassettes/ssh-push-project-denied-401-text-html.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: post - uri: http://localhost:3000/api/v4/internal/allowed/secure + uri: http://localhost:3000/api/v4/internal/allowed body: encoding: US-ASCII string: action=git-receive-pack&changes=0000000000000000000000000000000000000000+92d0970eefd7acb6d548878925ce2208cfe2d2ec+refs%2Fheads%2Fbranch4&gl_repository&project=gitlab-org%2Fgitlab-test.git&protocol=ssh&env=%7B%7D&key_id=2&secret_token=0a3938d9d95d807e94d937af3a4fbbea%0A diff --git a/spec/vcr_cassettes/ssh-push-project-denied-401-text-plain.yml b/spec/vcr_cassettes/ssh-push-project-denied-401-text-plain.yml index c32d87a..46d9a1d 100644 --- a/spec/vcr_cassettes/ssh-push-project-denied-401-text-plain.yml +++ b/spec/vcr_cassettes/ssh-push-project-denied-401-text-plain.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: post - uri: http://localhost:3000/api/v4/internal/allowed/secure + uri: http://localhost:3000/api/v4/internal/allowed body: encoding: US-ASCII string: action=git-receive-pack&changes=0000000000000000000000000000000000000000+92d0970eefd7acb6d548878925ce2208cfe2d2ec+refs%2Fheads%2Fbranch4&gl_repository&project=gitlab-org%2Fgitlab-test.git&protocol=ssh&env=%7B%7D&key_id=2&secret_token=0a3938d9d95d807e94d937af3a4fbbea%0A diff --git a/spec/vcr_cassettes/ssh-push-project-denied-401.yml b/spec/vcr_cassettes/ssh-push-project-denied-401.yml index 468b071..77248e2 100644 --- a/spec/vcr_cassettes/ssh-push-project-denied-401.yml +++ b/spec/vcr_cassettes/ssh-push-project-denied-401.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: post - uri: http://localhost:3000/api/v4/internal/allowed/secure + uri: http://localhost:3000/api/v4/internal/allowed body: encoding: US-ASCII string: action=git-receive-pack&changes=0000000000000000000000000000000000000000+92d0970eefd7acb6d548878925ce2208cfe2d2ec+refs%2Fheads%2Fbranch4&gl_repository&project=gitlab-org%2Fgitlab-test.git&protocol=ssh&env=%7B%7D&key_id=2&secret_token=0a3938d9d95d807e94d937af3a4fbbea%0A diff --git a/spec/vcr_cassettes/ssh-push-project-denied.yml b/spec/vcr_cassettes/ssh-push-project-denied.yml index 946db72..0e6f8c8 100644 --- a/spec/vcr_cassettes/ssh-push-project-denied.yml +++ b/spec/vcr_cassettes/ssh-push-project-denied.yml @@ -2,7 +2,7 @@ http_interactions: - request: method: post - uri: http://localhost:3000/api/v4/internal/allowed/secure + uri: http://localhost:3000/api/v4/internal/allowed body: encoding: US-ASCII string: action=git-receive-pack&changes=0000000000000000000000000000000000000000+92d0970eefd7acb6d548878925ce2208cfe2d2ec+refs%2Fheads%2Fbranch4&gl_repository&project=gitlab-org%2Fgitlab-test.git&protocol=ssh&env=%7B%7D&key_id=2&secret_token=0a3938d9d95d807e94d937af3a4fbbea%0A |