summaryrefslogtreecommitdiff
path: root/config
diff options
context:
space:
mode:
authorLin Jen-Shin <godfat@godfat.org>2016-11-04 02:41:01 +0800
committerLin Jen-Shin <godfat@godfat.org>2016-11-04 02:41:01 +0800
commit6a00cf1b9da3bc8bb1a9a270defd154bf7c93580 (patch)
treee82ee2a2bc25249f1a0f1a52344f277f87c3c010 /config
parentf3c3d8e63ba078e55c0ce516e19ec11cea429e43 (diff)
parent3ac3106e585273b1d9c673c71f794ae018698f83 (diff)
downloadgitlab-ce-6a00cf1b9da3bc8bb1a9a270defd154bf7c93580.tar.gz
Merge remote-tracking branch 'upstream/master' into show-status-from-branch
* upstream/master: (74 commits) Clarify the author field for the changelog documentation Add and update .gitignore & .gitlab-ci.yml templates for 8.14 Update "Installation from source" guide for 8.14.0 Add CHANGELOG entries for latest patches Merge branch 'fix/import-export-symlink-vulnerability' into 'security' Merge branch 'fix/import-projectmember-security' into 'security' Use stubs instead of modifying global states Add changelog instructions to CHANGELOG.md Try not to include anything globally! Update help banner for bin/changelog Add a `--force` option to bin/changelog Update examples in changelog docs to use single quotes around title Use the server's base URL without relative URL part when creating links in JIRA Update docs and test description Update docs and unexpose token Make ESLint ignore instrumented files for coverage analysis (!7236) Initialize form validation on new group form. Check that JavaScript file names match convention (!7238) Unchange username_validator. Move snake_case to camelCase. ...
Diffstat (limited to 'config')
-rw-r--r--config/gitlab.yml.example4
-rw-r--r--config/initializers/0_post_deployment_migrations.rb12
-rw-r--r--config/initializers/sidekiq.rb16
3 files changed, 31 insertions, 1 deletions
diff --git a/config/gitlab.yml.example b/config/gitlab.yml.example
index 3451b68cea5..699ab6075b6 100644
--- a/config/gitlab.yml.example
+++ b/config/gitlab.yml.example
@@ -432,7 +432,9 @@ production: &base
## Repositories settings
repositories:
# Paths where repositories can be stored. Give the canonicalized absolute pathname.
- # NOTE: REPOS PATHS MUST NOT CONTAIN ANY SYMLINK!!!
+ # IMPORTANT: None of the path components may be symlink, because
+ # gitlab-shell invokes Dir.pwd inside the repository path and that results
+ # real path not the symlink.
storages: # You must have at least a `default` storage path.
default: /home/git/repositories/
diff --git a/config/initializers/0_post_deployment_migrations.rb b/config/initializers/0_post_deployment_migrations.rb
new file mode 100644
index 00000000000..0068a03d214
--- /dev/null
+++ b/config/initializers/0_post_deployment_migrations.rb
@@ -0,0 +1,12 @@
+# Post deployment migrations are included by default. This file must be loaded
+# before other initializers as Rails may otherwise memoize a list of migrations
+# excluding the post deployment migrations.
+unless ENV['SKIP_POST_DEPLOYMENT_MIGRATIONS']
+ path = Rails.root.join('db', 'post_migrate').to_s
+
+ Rails.application.config.paths['db/migrate'] << path
+
+ # Rails memoizes migrations at certain points where it won't read the above
+ # path just yet. As such we must also update the following list of paths.
+ ActiveRecord::Migrator.migrations_paths << path
+end
diff --git a/config/initializers/sidekiq.rb b/config/initializers/sidekiq.rb
index f7e714cd6bc..0455a98dbfe 100644
--- a/config/initializers/sidekiq.rb
+++ b/config/initializers/sidekiq.rb
@@ -42,3 +42,19 @@ end
Sidekiq.configure_client do |config|
config.redis = redis_config_hash
end
+
+# The Sidekiq client API always adds the queue to the Sidekiq queue
+# list, but mail_room and gitlab-shell do not. This is only necessary
+# for monitoring.
+config = YAML.load_file(Rails.root.join('config', 'sidekiq_queues.yml').to_s)
+
+begin
+ Sidekiq.redis do |conn|
+ conn.pipelined do
+ config[:queues].each do |queue|
+ conn.sadd('queues', queue[0])
+ end
+ end
+ end
+rescue Redis::BaseError, SocketError
+end