config.ru 677 Bytes
Newer Older
Benjamin Neff's avatar
Benjamin Neff committed
1
#   Copyright (c) 2010-2011, Diaspora Inc.  This file is
Raphael's avatar
Raphael committed
2
#   licensed under the Affero General Public License version 3 or later.  See
Raphael's avatar
Raphael committed
3
#   the COPYRIGHT file.
4

Raphael Sofaer's avatar
Raphael Sofaer committed
5 6
# This file is used by Rack-based servers to start the application.

Benjamin Neff's avatar
Benjamin Neff committed
7 8 9
require ::File.expand_path("../config/environment",  __FILE__)
require ::File.expand_path("../lib/unicorn_killer",  __FILE__)
require ::File.expand_path("../lib/rack/internet_explorer_version", __FILE__)
10

Benjamin Neff's avatar
Benjamin Neff committed
11
# Kill unicorn workers really aggressively (at 300mb)
12 13 14
if defined?(Unicorn)
  use UnicornKiller::Oom, 300 * 1024
end
15
use Rack::Deflater
Benjamin Neff's avatar
Benjamin Neff committed
16
use Rack::InternetExplorerVersion, minimum: 9
David McMullin's avatar
David McMullin committed
17 18
use Rack::Protection::FrameOptions

19
run Diaspora::Application