diff options
author | Sytse Sijbrandij <sytse@gitlab.com> | 2015-02-13 23:38:50 +0000 |
---|---|---|
committer | Sytse Sijbrandij <sytse@gitlab.com> | 2015-02-13 23:38:50 +0000 |
commit | 5725b6daad2f403f13112cfcafa5b45ac126c0ca (patch) | |
tree | 6147efeebcf537e0b31e057489e601205a245981 /doc/integration/github.md | |
parent | d785b20c43b114bbae385a5446f9369370fbd3bf (diff) | |
parent | d76c5824bc05640d276be96f7853f2d266fd6750 (diff) | |
download | gitlab-ce-5725b6daad2f403f13112cfcafa5b45ac126c0ca.tar.gz |
Merge branch 'update_omniauth_integration_document' into 'master'
Update omniauth integration documentation
See merge request !1522
Diffstat (limited to 'doc/integration/github.md')
-rw-r--r-- | doc/integration/github.md | 38 |
1 files changed, 31 insertions, 7 deletions
diff --git a/doc/integration/github.md b/doc/integration/github.md index a586334b98d..c9c27859c5e 100644 --- a/doc/integration/github.md +++ b/doc/integration/github.md @@ -21,20 +21,44 @@ To enable the GitHub OmniAuth provider you must register your application with G 1. On your GitLab server, open the configuration file. + For omnibus package: + + ```sh + sudo editor /etc/gitlab/gitlab.rb + ``` + + For instalations from source: + ```sh - cd /home/git/gitlab + cd /home/git/gitlab - sudo -u git -H editor config/gitlab.yml + sudo -u git -H editor config/gitlab.yml ``` -1. Find the section dealing with OmniAuth. See [Initial OmniAuth Configuration](README.md#initial-omniauth-configuration) for more details. +1. See [Initial OmniAuth Configuration](README.md#initial-omniauth-configuration) for inital settings. + +1. Add the provider configuration: + + For omnibus package: + + ```ruby + gitlab_rails['omniauth_providers'] = [ + { + "name" => "github", + "app_id" => "YOUR APP ID", + "app_secret" => "YOUR APP SECRET", + "url" => "https://github.com/", + "args" => { "scope" => "user:email" } } + } + ] + ``` -1. Under `providers:` uncomment (or add) lines that look like the following: + For installation from source: ``` - - { name: 'github', app_id: 'YOUR APP ID', - app_secret: 'YOUR APP SECRET', - args: { scope: 'user:email' } } + - { name: 'github', app_id: 'YOUR APP ID', + app_secret: 'YOUR APP SECRET', + args: { scope: 'user:email' } } ``` 1. Change 'YOUR APP ID' to the client ID from the GitHub application page from step 7. |