Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/config
diff options
context:
space:
mode:
authorLuke "Jared" Bennett <lbennett@gitlab.com>2017-05-03 15:03:57 +0300
committerLuke "Jared" Bennett <lbennett@gitlab.com>2017-05-03 15:03:57 +0300
commit7788118c3d059ef93bcc49c1b6b6ec7d72faf8b5 (patch)
tree6642a358083285d90234f8d4ba27d61bfd9448bd /config
parent637ed8a21e9f9457d1b194f9c591a0813c20cc3e (diff)
parentcac04fbd777ff992bbd92e9ae3cded01d45b07d0 (diff)
Merge remote-tracking branch 'origin/master' into add-sentry-js-again-with-vue
Diffstat (limited to 'config')
-rw-r--r--config/initializers/active_record_query_trace.rb5
-rw-r--r--config/initializers/carrierwave.rb2
-rw-r--r--config/initializers/rspec_profiling.rb8
-rw-r--r--config/routes/admin.rb6
-rw-r--r--config/routes/project.rb6
-rw-r--r--config/routes/snippets.rb11
-rw-r--r--config/webpack.config.js5
7 files changed, 28 insertions, 15 deletions
diff --git a/config/initializers/active_record_query_trace.rb b/config/initializers/active_record_query_trace.rb
deleted file mode 100644
index 4b3c2803b3b..00000000000
--- a/config/initializers/active_record_query_trace.rb
+++ /dev/null
@@ -1,5 +0,0 @@
-if ENV['ENABLE_QUERY_TRACE']
- require 'active_record_query_trace'
-
- ActiveRecordQueryTrace.enabled = 'true'
-end
diff --git a/config/initializers/carrierwave.rb b/config/initializers/carrierwave.rb
index 1933afcbfb1..cd7df44351a 100644
--- a/config/initializers/carrierwave.rb
+++ b/config/initializers/carrierwave.rb
@@ -6,6 +6,8 @@ if File.exist?(aws_file)
AWS_CONFIG = YAML.load(File.read(aws_file))[Rails.env]
CarrierWave.configure do |config|
+ config.fog_provider = 'fog/aws'
+
config.fog_credentials = {
provider: 'AWS', # required
aws_access_key_id: AWS_CONFIG['access_key_id'], # required
diff --git a/config/initializers/rspec_profiling.rb b/config/initializers/rspec_profiling.rb
index b909cc5b9a4..a7efd74f09e 100644
--- a/config/initializers/rspec_profiling.rb
+++ b/config/initializers/rspec_profiling.rb
@@ -36,10 +36,10 @@ if Rails.env.test?
RspecProfiling::Collectors::PSQL.prepend(RspecProfilingExt::PSQL)
config.collector = RspecProfiling::Collectors::PSQL
end
- end
- if ENV.has_key?('CI') && ENV['GITLAB_DATABASE'] == 'postgresql'
- RspecProfiling::VCS::Git.prepend(RspecProfilingExt::Git)
- RspecProfiling::Run.prepend(RspecProfilingExt::Run)
+ if ENV.key?('CI')
+ RspecProfiling::VCS::Git.prepend(RspecProfilingExt::Git)
+ RspecProfiling::Run.prepend(RspecProfilingExt::Run)
+ end
end
end
diff --git a/config/routes/admin.rb b/config/routes/admin.rb
index 52ba10604d4..48993420ed9 100644
--- a/config/routes/admin.rb
+++ b/config/routes/admin.rb
@@ -50,8 +50,10 @@ namespace :admin do
resources :deploy_keys, only: [:index, :new, :create, :destroy]
- resources :hooks, only: [:index, :create, :destroy] do
- get :test
+ resources :hooks, only: [:index, :create, :edit, :update, :destroy] do
+ member do
+ get :test
+ end
end
resources :broadcast_messages, only: [:index, :edit, :create, :update, :destroy] do
diff --git a/config/routes/project.rb b/config/routes/project.rb
index 115ae2324b3..894faeb6188 100644
--- a/config/routes/project.rb
+++ b/config/routes/project.rb
@@ -44,7 +44,7 @@ constraints(ProjectUrlConstrainer.new) do
resources :snippets, concerns: :awardable, constraints: { id: /\d+/ } do
member do
- get 'raw'
+ get :raw
post :mark_as_spam
end
end
@@ -138,6 +138,8 @@ constraints(ProjectUrlConstrainer.new) do
collection do
get :folder, path: 'folders/*id', constraints: { format: /(html|json)/ }
end
+
+ resources :deployments, only: [:index]
end
resource :cycle_analytics, only: [:show]
@@ -185,7 +187,7 @@ constraints(ProjectUrlConstrainer.new) do
end
end
- resources :hooks, only: [:index, :create, :destroy], constraints: { id: /\d+/ } do
+ resources :hooks, only: [:index, :create, :edit, :update, :destroy], constraints: { id: /\d+/ } do
member do
get :test
end
diff --git a/config/routes/snippets.rb b/config/routes/snippets.rb
index 56534f677be..dae83734fe6 100644
--- a/config/routes/snippets.rb
+++ b/config/routes/snippets.rb
@@ -1,10 +1,17 @@
resources :snippets, concerns: :awardable do
member do
- get 'raw'
- get 'download'
+ get :raw
post :mark_as_spam
post :preview_markdown
end
+
+ scope module: :snippets do
+ resources :notes, only: [:index, :create, :destroy, :update], concerns: :awardable, constraints: { id: /\d+/ } do
+ member do
+ delete :delete_attachment
+ end
+ end
+ end
end
get '/s/:username', to: redirect('/u/%{username}/snippets'),
diff --git a/config/webpack.config.js b/config/webpack.config.js
index fc5754b6db9..ea699b1ecba 100644
--- a/config/webpack.config.js
+++ b/config/webpack.config.js
@@ -79,6 +79,11 @@ var config = {
loader: 'raw-loader',
},
{
+ test: /\.gif$/,
+ loader: 'url-loader',
+ query: { mimetype: 'image/gif' },
+ },
+ {
test: /\.(worker\.js|pdf)$/,
exclude: /node_modules/,
loader: 'file-loader',