summaryrefslogtreecommitdiff
path: root/config
diff options
context:
space:
mode:
Diffstat (limited to 'config')
-rw-r--r--config/initializers/01_secret_token.rb (renamed from config/initializers/secret_token.rb)3
-rw-r--r--config/settings.rb4
2 files changed, 7 insertions, 0 deletions
diff --git a/config/initializers/secret_token.rb b/config/initializers/01_secret_token.rb
index 750a5b34f3b..02bded43083 100644
--- a/config/initializers/secret_token.rb
+++ b/config/initializers/01_secret_token.rb
@@ -1,3 +1,6 @@
+# This file needs to be loaded BEFORE any initializers that attempt to
+# prepend modules that require access to secrets (e.g. EE's 0_as_concern.rb).
+#
# Be sure to restart your server when you modify this file.
require 'securerandom'
diff --git a/config/settings.rb b/config/settings.rb
index 69d637761ea..4aa903109ea 100644
--- a/config/settings.rb
+++ b/config/settings.rb
@@ -85,6 +85,10 @@ class Settings < Settingslogic
File.expand_path(path, Rails.root)
end
+ def attr_encrypted_db_key_base
+ Gitlab::Application.secrets.db_key_base[0..31]
+ end
+
private
def base_url(config)