如何将一个starman请求代理到Apache?

时间:2012-09-03 03:35:12

标签: perl psgi starman

我使用starman作为我的webapp。 Apache Web服务器侦听端口8080。 我想在starman中将这个请求重写为'/request'这个Apache Web服务器。我试着找到一些下午,但我找到了一些帮助我的例子。

1 个答案:

答案 0 :(得分:1)

Plack::App::Proxy允许您代理app.psgi中的其他网络服务器。修改自概要:

use Plack::Builder;

# proxy all requests for /request to 127.0.0.1:8080
builder {
    mount "/request" => Plack::App::Proxy->new(remote => "http://127.0.0.1:8080")->to_app;
};