summaryrefslogtreecommitdiff
path: root/config
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-08-19 06:10:04 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2020-08-19 06:10:04 +0000
commit0bfb62457ba5122c9bf30bed3ecd20759a9a16bd (patch)
tree8e18296b4f9b889df037dd07d634884a7566ed8c /config
parent7fdacd20dec0db3507643c7e89e9f3d35892adef (diff)
downloadgitlab-ce-0bfb62457ba5122c9bf30bed3ecd20759a9a16bd.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'config')
-rw-r--r--config/initializers/time_zone.rb7
1 files changed, 7 insertions, 0 deletions
diff --git a/config/initializers/time_zone.rb b/config/initializers/time_zone.rb
index ee246e67d66..bca7411ad63 100644
--- a/config/initializers/time_zone.rb
+++ b/config/initializers/time_zone.rb
@@ -1 +1,8 @@
Time.zone = Gitlab.config.gitlab.time_zone || Time.zone
+# The default is normally set by Rails in the
+# active_support.initialize_time_zone Railtie, but we need to set it
+# here because the config settings aren't available until after that
+# runs. We set the default to ensure multi-threaded servers have the
+# right value.
+Time.zone_default = Time.zone
+Rails.application.config.time_zone = Time.zone