summaryrefslogtreecommitdiff
path: root/config
diff options
context:
space:
mode:
authorDouglas Barbosa Alexandre <dbalexandre@gmail.com>2016-12-16 23:25:14 +0000
committerDouglas Barbosa Alexandre <dbalexandre@gmail.com>2016-12-16 23:25:14 +0000
commita22be3065dc9c80d3a18ca81eda480b9c39e35a6 (patch)
treed29fc79464dbf3f1fd09d034a4b73c8eb230a9e3 /config
parent12a7e717d7b9fdd265d54a9c5bd07394e304b187 (diff)
parenta3be4aeb7a71cc940394a5f13d09e79fcafdb1d5 (diff)
downloadgitlab-ce-a22be3065dc9c80d3a18ca81eda480b9c39e35a6.tar.gz
Merge branch 'bitbucket-oauth2' into 'master'
Refactor Bitbucket importer to use BitBucket API Version 2 ## What does this MR do? ## Are there points in the code the reviewer needs to double check? ## Why was this MR needed? ## What are the relevant issue numbers? https://gitlab.com/gitlab-org/gitlab-ce/issues/19946 ## Screenshots (if relevant) This MR needs the following permissions in the Bitbucket OAuth settings: ![image](/uploads/a26ae5e430a724bf581a92da7028ce3c/image.png) - [] ## Does this MR meet the acceptance criteria? - [ ] [CHANGELOG](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CHANGELOG) entry added - [ ] [Documentation created/updated](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/development/doc_styleguide.md) - [ ] API support added - Tests - [ ] Added for this feature/bug - [ ] All builds are passing - [ ] Conform by the [style guides](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CONTRIBUTING.md#style-guides) - [ ] Branch has no merge conflicts with `master` (if you do - rebase it please) - [ ] [Squashed related commits together](https://git-scm.com/book/en/Git-Tools-Rewriting-History#Squashing-Commits) See merge request !5995
Diffstat (limited to 'config')
-rw-r--r--config/initializers/omniauth.rb6
-rw-r--r--config/initializers/public_key.rb2
2 files changed, 6 insertions, 2 deletions
diff --git a/config/initializers/omniauth.rb b/config/initializers/omniauth.rb
index 26c30e523a7..ab5a0561b8c 100644
--- a/config/initializers/omniauth.rb
+++ b/config/initializers/omniauth.rb
@@ -26,3 +26,9 @@ if Gitlab.config.omniauth.enabled
end
end
end
+
+module OmniAuth
+ module Strategies
+ autoload :Bitbucket, Rails.root.join('lib', 'omniauth', 'strategies', 'bitbucket')
+ end
+end
diff --git a/config/initializers/public_key.rb b/config/initializers/public_key.rb
deleted file mode 100644
index e4f09a2d020..00000000000
--- a/config/initializers/public_key.rb
+++ /dev/null
@@ -1,2 +0,0 @@
-path = File.expand_path("~/.ssh/bitbucket_rsa.pub")
-Gitlab::BitbucketImport.public_key = File.read(path) if File.exist?(path)