summaryrefslogtreecommitdiff
path: root/config.ru
diff options
context:
space:
mode:
authorKamil TrzciƄski <ayufan@ayufan.eu>2018-11-27 17:12:49 +0100
committerStan Hu <stanhu@gmail.com>2018-11-28 08:34:32 -0800
commitdc962788fa7589e948479f609a6feb29404d217b (patch)
tree60f9cad6d77f2aa71de85a7c4f0efef4bce8d636 /config.ru
parent56da230826f76f0c16fbb5b7de4ced28d8f5cdae (diff)
downloadgitlab-ce-dc962788fa7589e948479f609a6feb29404d217b.tar.gz
Add monkey patch to unicorn to fix eof? problem
Rack with Unicorn is unable to handle chunked requests due to private `eof?` method. This exposes `eof?` not changing `rack` behavior. Issue: https://gitlab.com/gitlab-org/gitlab-ee/issues/8539
Diffstat (limited to 'config.ru')
-rw-r--r--config.ru4
1 files changed, 4 insertions, 0 deletions
diff --git a/config.ru b/config.ru
index 405d01863ac..a5d055334dd 100644
--- a/config.ru
+++ b/config.ru
@@ -13,6 +13,10 @@ if defined?(Unicorn)
# Max memory size (RSS) per worker
use Unicorn::WorkerKiller::Oom, min, max
end
+
+ # Monkey patch for fixing Rack 2.0.6 bug:
+ # https://gitlab.com/gitlab-org/gitlab-ee/issues/8539
+ Unicorn::StreamInput.send(:public, :eof?) # rubocop:disable GitlabSecurity/PublicSend
end
require ::File.expand_path('../config/environment', __FILE__)