summaryrefslogtreecommitdiff
path: root/config
diff options
context:
space:
mode:
authorLin Jen-Shin <godfat@godfat.org>2017-09-25 15:42:34 +0800
committerLin Jen-Shin <godfat@godfat.org>2017-09-25 15:42:34 +0800
commit239332eed3fa870fd41be83864882c0f389840d8 (patch)
treea81aba7617f391f9cb4a67339faa9de67b4426d3 /config
parent961b0849e5098dae74050f6c49ebf3011ce072b7 (diff)
parent7da72a0de296e430378c7eb85fc486a01f3163bd (diff)
downloadgitlab-ce-239332eed3fa870fd41be83864882c0f389840d8.tar.gz
Merge remote-tracking branch 'upstream/master' into no-ivar-in-modules
* upstream/master: (168 commits) Update CHANGELOG.md for 10.0.1 Remove Grit settings from default settings Fix duplicate key errors in PostDeployMigrateUserExternalMailData migration Workaround for #38259 Workaround for n+1 in Projects::TreeController#show Removed old icons from project page Make branches page translatable fix typo in icons section Don't show it if there's no project. Update CHANGELOG.md for 10.0.0 Inform user that current shared projects will remain shared Allow the git circuit breaker to correctly handle missing repository storages Reserve refs/replace cos `git-replace` is using it Resolve "Better SVG Usage in the Frontend" Replace the 'project/service.feature' spinach test with an rspec analog Replace the 'project/shortcuts.feature' spinach test with an rspec analog Removed two legacy config options Fix rendering double note issue. IssueNotes: Switch back to Write pane when note cancel or submit. Upgrade Nokogiri because of CVE-2017-9050 ...
Diffstat (limited to 'config')
-rw-r--r--config/dependency_decisions.yml12
-rw-r--r--config/gitlab.yml.example6
-rw-r--r--config/initializers/1_settings.rb4
-rw-r--r--config/initializers/doorkeeper.rb2
-rw-r--r--config/initializers/lograge.rb7
-rw-r--r--config/initializers/postgresql_opclasses_support.rb2
-rw-r--r--config/sidekiq_queues.yml1
-rw-r--r--config/svg.config.js48
-rw-r--r--config/webpack.config.js1
9 files changed, 70 insertions, 13 deletions
diff --git a/config/dependency_decisions.yml b/config/dependency_decisions.yml
index 6c5c8cad270..db31b01a7d2 100644
--- a/config/dependency_decisions.yml
+++ b/config/dependency_decisions.yml
@@ -452,3 +452,15 @@
:why: https://github.com/jaredhanson/utils-merge/blob/v1.0.0/LICENSE
:versions: []
:when: 2017-09-16 05:18:26.193764000 Z
+- - :approve
+ - svg4everybody
+ - :who: Tim Zallmann
+ :why: CC0 1.0 - https://github.com/jonathantneal/svg4everybody/blob/master/LICENSE.md
+ :versions: []
+ :when: 2017-09-13 17:31:16.425819400 Z
+- - :approve
+ - gitlab-svgs
+ - :who: Tim Zallmann
+ :why: Our own library - https://gitlab.com/gitlab-org/gitlab-svgs
+ :versions: []
+ :when: 2017-09-19 14:36:32.795496000 Z
diff --git a/config/gitlab.yml.example b/config/gitlab.yml.example
index cd44f888d3f..9b496822e93 100644
--- a/config/gitlab.yml.example
+++ b/config/gitlab.yml.example
@@ -577,12 +577,6 @@ production: &base
# Use the default values unless you really know what you are doing
git:
bin_path: /usr/bin/git
- # The next value is the maximum memory size grit can use
- # Given in number of bytes per git object (e.g. a commit)
- # This value can be increased if you have very large commits
- max_size: 20971520 # 20.megabytes
- # Git timeout to read a commit, in seconds
- timeout: 10
## Webpack settings
# If enabled, this will tell rails to serve frontend assets from the webpack-dev-server running
diff --git a/config/initializers/1_settings.rb b/config/initializers/1_settings.rb
index 94429ee91a9..27c1ecc7b23 100644
--- a/config/initializers/1_settings.rb
+++ b/config/initializers/1_settings.rb
@@ -499,9 +499,7 @@ Settings.backup['upload']['storage_class'] ||= nil
# Git
#
Settings['git'] ||= Settingslogic.new({})
-Settings.git['max_size'] ||= 20971520 # 20.megabytes
-Settings.git['bin_path'] ||= '/usr/bin/git'
-Settings.git['timeout'] ||= 10
+Settings.git['bin_path'] ||= '/usr/bin/git'
# Important: keep the satellites.path setting until GitLab 9.0 at
# least. This setting is fed to 'rm -rf' in
diff --git a/config/initializers/doorkeeper.rb b/config/initializers/doorkeeper.rb
index 40e635bf2cf..b89f0419b91 100644
--- a/config/initializers/doorkeeper.rb
+++ b/config/initializers/doorkeeper.rb
@@ -58,7 +58,7 @@ Doorkeeper.configure do
# For more information go to
# https://github.com/doorkeeper-gem/doorkeeper/wiki/Using-Scopes
default_scopes(*Gitlab::Auth::DEFAULT_SCOPES)
- optional_scopes(*Gitlab::Auth::OPTIONAL_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/lograge.rb b/config/initializers/lograge.rb
index 21fe8d72459..8560d24526f 100644
--- a/config/initializers/lograge.rb
+++ b/config/initializers/lograge.rb
@@ -12,13 +12,18 @@ unless Sidekiq.server?
config.lograge.logger = ActiveSupport::Logger.new(filename)
# Add request parameters to log output
config.lograge.custom_options = lambda do |event|
- {
+ payload = {
time: event.time.utc.iso8601(3),
params: event.payload[:params].except(*%w(controller action format)),
remote_ip: event.payload[:remote_ip],
user_id: event.payload[:user_id],
username: event.payload[:username]
}
+
+ gitaly_calls = Gitlab::GitalyClient.get_request_count
+ payload[:gitaly_calls] = gitaly_calls if gitaly_calls > 0
+
+ payload
end
end
end
diff --git a/config/initializers/postgresql_opclasses_support.rb b/config/initializers/postgresql_opclasses_support.rb
index 820cc89ef57..c2f3023b330 100644
--- a/config/initializers/postgresql_opclasses_support.rb
+++ b/config/initializers/postgresql_opclasses_support.rb
@@ -127,7 +127,7 @@ module ActiveRecord
orders = desc_order_columns.any? ? Hash[desc_order_columns.map {|order_column| [order_column, :desc]}] : {}
where = inddef.scan(/WHERE (.+)$/).flatten[0]
using = inddef.scan(/USING (.+?) /).flatten[0].to_sym
- opclasses = Hash[inddef.scan(/\((.+)\)$/).flatten[0].split(',').map do |column_and_opclass|
+ opclasses = Hash[inddef.scan(/\((.+?)\)(?:$| WHERE )/).flatten[0].split(',').map do |column_and_opclass|
column, opclass = column_and_opclass.split(' ').map(&:strip)
[column, opclass] if opclass
end.compact]
diff --git a/config/sidekiq_queues.yml b/config/sidekiq_queues.yml
index 24c001362c6..d169c38a693 100644
--- a/config/sidekiq_queues.yml
+++ b/config/sidekiq_queues.yml
@@ -38,7 +38,6 @@
- [invalid_gpg_signature_update, 2]
- [create_gpg_signature, 2]
- [upload_checksum, 1]
- - [use_key, 1]
- [repository_fork, 1]
- [repository_import, 1]
- [project_service, 1]
diff --git a/config/svg.config.js b/config/svg.config.js
new file mode 100644
index 00000000000..be72741abec
--- /dev/null
+++ b/config/svg.config.js
@@ -0,0 +1,48 @@
+/* eslint-disable no-commonjs */
+const path = require('path');
+const fs = require('fs');
+
+const sourcePath = path.join('node_modules', 'gitlab-svgs', 'dist');
+const sourcePathIllustrations = path.join('node_modules', 'gitlab-svgs', 'dist', 'illustrations');
+const destPath = path.normalize(path.join('app', 'assets', 'images'));
+
+// Actual Task copying the 2 files + all illustrations
+copyFileSync(path.join(sourcePath, 'icons.svg'), destPath);
+copyFileSync(path.join(sourcePath, 'icons.json'), destPath);
+copyFolderRecursiveSync(sourcePathIllustrations, destPath);
+
+// Helper Functions
+function copyFileSync(source, target) {
+ var targetFile = target;
+ //if target is a directory a new file with the same name will be created
+ if (fs.existsSync(target)) {
+ if (fs.lstatSync(target).isDirectory()) {
+ targetFile = path.join(target, path.basename(source));
+ }
+ }
+ console.log(`Copy SVG File : ${targetFile}`);
+ fs.writeFileSync(targetFile, fs.readFileSync(source));
+}
+
+function copyFolderRecursiveSync(source, target) {
+ var files = [];
+
+ //check if folder needs to be created or integrated
+ var targetFolder = path.join(target, path.basename(source));
+ if (!fs.existsSync(targetFolder)) {
+ fs.mkdirSync(targetFolder);
+ }
+
+ //copy
+ if (fs.lstatSync(source).isDirectory()) {
+ files = fs.readdirSync(source);
+ files.forEach(function (file) {
+ var curSource = path.join(source, file);
+ if (fs.lstatSync(curSource).isDirectory()) {
+ copyFolderRecursiveSync(curSource, targetFolder);
+ } else {
+ copyFileSync(curSource, targetFolder);
+ }
+ });
+ }
+}
diff --git a/config/webpack.config.js b/config/webpack.config.js
index 6b0cd023291..3404715fe30 100644
--- a/config/webpack.config.js
+++ b/config/webpack.config.js
@@ -45,6 +45,7 @@ var config = {
group: './group.js',
groups: './groups/index.js',
groups_list: './groups_list.js',
+ help: './help/help.js',
how_to_merge: './how_to_merge.js',
issue_show: './issue_show/index.js',
integrations: './integrations',