diff options
author | Zeger-Jan van de Weg <zegerjan@gitlab.com> | 2016-12-18 15:59:09 +0300 |
---|---|---|
committer | Zeger-Jan van de Weg <zegerjan@gitlab.com> | 2016-12-18 15:59:09 +0300 |
commit | a9d9895dc7b4c024471f49a61166a6bb402eab9e (patch) | |
tree | a36edcc9449123a9fd4112dc18c5c18216ae07a1 /config | |
parent | b23f32a735459f1c76ac8232f9de06942b1d2f8a (diff) | |
parent | 546fa165ff728bc2d25ed9b55b95dd1d48139d4a (diff) |
Merge branch 'master' into 'zj-mattermost-slash-config'
# Conflicts:
# config/gitlab.yml.example
# lib/mattermost/session.rb
# spec/lib/mattermost/session_spec.rb
Diffstat (limited to 'config')
-rw-r--r-- | config/application.rb | 6 | ||||
-rw-r--r-- | config/gitlab.yml.example | 7 | ||||
-rw-r--r-- | config/initializers/1_settings.rb | 7 | ||||
-rw-r--r-- | config/initializers/doorkeeper.rb | 4 | ||||
-rw-r--r-- | config/initializers/math_lexer.rb | 2 | ||||
-rw-r--r-- | config/initializers/omniauth.rb | 6 | ||||
-rw-r--r-- | config/initializers/public_key.rb | 2 | ||||
-rw-r--r-- | config/initializers/sidekiq.rb | 2 | ||||
-rw-r--r-- | config/initializers/workhorse_multipart.rb | 3 | ||||
-rw-r--r-- | config/locales/doorkeeper.en.yml | 1 | ||||
-rw-r--r-- | config/routes/project.rb | 13 |
11 files changed, 43 insertions, 10 deletions
diff --git a/config/application.rb b/config/application.rb index 0aa2873f94a..782a7a36895 100644 --- a/config/application.rb +++ b/config/application.rb @@ -45,7 +45,7 @@ module Gitlab # # Parameters filtered: # - Password (:password, :password_confirmation) - # - Private tokens (:private_token, :authentication_token) + # - Private tokens # - Two-factor tokens (:otp_attempt) # - Repo/Project Import URLs (:import_url) # - Build variables (:variables) @@ -60,11 +60,13 @@ module Gitlab encrypted_key hook import_url + incoming_email_token key otp_attempt password password_confirmation private_token + runners_token secret_token sentry_dsn variables @@ -85,6 +87,8 @@ module Gitlab config.assets.precompile << "print.css" config.assets.precompile << "notify.css" config.assets.precompile << "mailers/*.css" + config.assets.precompile << "katex.css" + config.assets.precompile << "katex.js" config.assets.precompile << "graphs/graphs_bundle.js" config.assets.precompile << "users/users_bundle.js" config.assets.precompile << "network/network_bundle.js" diff --git a/config/gitlab.yml.example b/config/gitlab.yml.example index e1e76e8bf73..f53a3d066df 100644 --- a/config/gitlab.yml.example +++ b/config/gitlab.yml.example @@ -153,10 +153,11 @@ production: &base # The location where LFS objects are stored (default: shared/lfs-objects). # storage_path: shared/lfs-objects - # For executing commands from GitLab on Mattermost + ## Mattermost + ## For enabling Add to Mattermost button mattermost: enabled: false - host: 'http://locahost:8065' + host: 'https://mattermost.example.com' ## Gravatar ## For Libravatar see: http://doc.gitlab.com/ce/customization/libravatar.html @@ -575,4 +576,4 @@ test: admin_group: '' staging: - <<: *base + <<: *base
\ No newline at end of file diff --git a/config/initializers/1_settings.rb b/config/initializers/1_settings.rb index 0ee1b1ec634..ddea325c6ca 100644 --- a/config/initializers/1_settings.rb +++ b/config/initializers/1_settings.rb @@ -262,6 +262,13 @@ Settings.lfs['enabled'] = true if Settings.lfs['enabled'].nil? Settings.lfs['storage_path'] = File.expand_path(Settings.lfs['storage_path'] || File.join(Settings.shared['path'], "lfs-objects"), Rails.root) # +# Mattermost +# +Settings['mattermost'] ||= Settingslogic.new({}) +Settings.mattermost['enabled'] = false if Settings.mattermost['enabled'].nil? +Settings.mattermost['host'] = nil unless Settings.mattermost.enabled + +# # Gravatar # Settings['gravatar'] ||= Settingslogic.new({}) diff --git a/config/initializers/doorkeeper.rb b/config/initializers/doorkeeper.rb index fc4b0a72add..88cd0f5f652 100644 --- a/config/initializers/doorkeeper.rb +++ b/config/initializers/doorkeeper.rb @@ -52,8 +52,8 @@ Doorkeeper.configure do # Define access token scopes for your provider # For more information go to # https://github.com/doorkeeper-gem/doorkeeper/wiki/Using-Scopes - default_scopes :api - # optional_scopes :write, :update + default_scopes(*Gitlab::Auth::DEFAULT_SCOPES) + optional_scopes(*Gitlab::Auth::OPTIONAL_SCOPES) # Change the way client credentials are retrieved from the request object. # By default it retrieves first from the `HTTP_AUTHORIZATION` header, then diff --git a/config/initializers/math_lexer.rb b/config/initializers/math_lexer.rb new file mode 100644 index 00000000000..8a3388a267e --- /dev/null +++ b/config/initializers/math_lexer.rb @@ -0,0 +1,2 @@ +# Touch the lexers so it is registered with Rouge +Rouge::Lexers::Math 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) diff --git a/config/initializers/sidekiq.rb b/config/initializers/sidekiq.rb index 1d7a3f03ace..5a7365bb0f6 100644 --- a/config/initializers/sidekiq.rb +++ b/config/initializers/sidekiq.rb @@ -34,7 +34,7 @@ Sidekiq.configure_server do |config| # Database pool should be at least `sidekiq_concurrency` + 2 # For more info, see: https://github.com/mperham/sidekiq/blob/master/4.0-Upgrade.md config = ActiveRecord::Base.configurations[Rails.env] || - Rails.application.config.database_configuration[Rails.env] + Rails.application.config.database_configuration[Rails.env] config['pool'] = Sidekiq.options[:concurrency] + 2 ActiveRecord::Base.establish_connection(config) Rails.logger.debug("Connection Pool size for Sidekiq Server is now: #{ActiveRecord::Base.connection.pool.instance_variable_get('@size')}") diff --git a/config/initializers/workhorse_multipart.rb b/config/initializers/workhorse_multipart.rb new file mode 100644 index 00000000000..3e2f25c354a --- /dev/null +++ b/config/initializers/workhorse_multipart.rb @@ -0,0 +1,3 @@ +Rails.application.configure do |config| + config.middleware.use(Gitlab::Middleware::Multipart) +end diff --git a/config/locales/doorkeeper.en.yml b/config/locales/doorkeeper.en.yml index a4032a21420..1d728282d90 100644 --- a/config/locales/doorkeeper.en.yml +++ b/config/locales/doorkeeper.en.yml @@ -59,6 +59,7 @@ en: unknown: "The access token is invalid" scopes: api: Access your API + read_user: Read user information flash: applications: diff --git a/config/routes/project.rb b/config/routes/project.rb index 3eddd3c2a0e..23d85368f1b 100644 --- a/config/routes/project.rb +++ b/config/routes/project.rb @@ -11,6 +11,18 @@ constraints(ProjectUrlConstrainer.new) do module: :projects, as: :project) do + resources :autocomplete_sources, only: [] do + collection do + get 'emojis' + get 'members' + get 'issues' + get 'merge_requests' + get 'labels' + get 'milestones' + get 'commands' + end + end + # # Templates # @@ -322,7 +334,6 @@ constraints(ProjectUrlConstrainer.new) do post :remove_export post :generate_new_export get :download_export - get :autocomplete_sources get :activity get :refs put :new_issue_address |