From 130d086666ccd825fcb13cf02fcf941b8fe661af Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Tue, 1 Feb 2011 15:05:52 -0800 Subject: preliminary reverse proxy Rack application This can be a starting point for developing Cool.io or EventMachine-based reverse proxy applications on Rainbows! Eventually Rainbows! could replace nginx for Unicorn users! Just don't consider this code production ready, yet, at all, it doesn't handle any sort of failover and has no automated tests, yet. --- examples/reverse_proxy.ru | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 examples/reverse_proxy.ru (limited to 'examples') diff --git a/examples/reverse_proxy.ru b/examples/reverse_proxy.ru new file mode 100644 index 0000000..fcb9e74 --- /dev/null +++ b/examples/reverse_proxy.ru @@ -0,0 +1,9 @@ +# see Rainbows::ReverseProxy RDoc +cfg = { + :upstreams => [ + "/tmp/.r.sock", + "http://bogomips.org/", + [ "http://10.6.6.6:666/", { :weight => 666 } ], + ] +} +run Rainbows::ReverseProxy.new(cfg) -- cgit v1.2.3-24-ge0c7