使用 lighttpd 服务 pharo seaside 3.0
我正在尝试使用lighttpd 为我的应用程序提供服务。在seaside 2.8中,以下内容在我的lighttpd.conf中起作用:
proxy.server = ( "/pharo" => (
( "host" => "127.0.0.1", "port" => 8080, "check-local" => "disable"))
)
但在seaside 3.0中,它重写了url以表示http://localhost/pharo 通过网络访问时。
有人能够用lighttpd 为pharo 和seaside 3 提供服务吗?
I am trying to serve my app with lighttpd. With seaside 2.8 the following worked in my lighttpd.conf:
proxy.server = ( "/pharo" => (
( "host" => "127.0.0.1", "port" => 8080, "check-local" => "disable"))
)
but with seaside 3.0 it rewrites the url to say http://localhost/pharo when accessing it over a network.
Anyone been able to serve pharo and seaside 3 with lighttpd?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
以下内容确实有效,我在此方法中取消注释了以下行,如下所示:
在我的应用程序的海边配置中,所有服务器设置(资源库 URL、服务器主机名、服务器路径、服务器端口、服务器协议)均未指定。
似乎海边正在尝试从某些应用程序父级获取服务器设置,但我无法追赶它。
编辑:好的,感谢 Lukas(请参阅评论),我所要做的就是将“Dispatcher:/”中找到的应用程序配置中的 #serverHostname 重置为 nil (未指定)。
The following did work, I uncommented the following line in this method like so:
In my seaside configuration of my application all the Server settings (Resource Base Url, Server Hostname, Server Path, Server Port, Server Protocol) are unspecified.
It seems like seaside is trying to get the server settings from some applications parent but i can't chase it.
EDIT: Ok, thanks to Lukas (see comment), all I had to do was reset the #serverHostname in my application configuration found at "Dispatcher: /" to nil (unspecified).
在应用程序的 Seaside 配置中,将您的 IP 地址放入“服务器主机名”字段中
In the seaside config of your app, put your IP address in the Server Hostname field
看起来 lighttpd 转发的原始主机名与 Apache 不同。将
#halt
放入WAUrl>>#takeServerParametersFromRequest:
中并检查传入请求aRequest
。大概有一个名为X-Forwarded-Host
的标头字段包含原始主机名,如果是这样,请按如下方式更改方法:如果此(或类似的内容)解决了您的问题,请 创建票证。
Looks like lighttpd forwards the original hostname different than Apache does. Put a
#halt
inWAUrl>>#takeServerParametersFromRequest:
and inspect the incoming requestaRequest
. Presumably there is a header field calledX-Forwarded-Host
that contains the original host name, if so change the method as follows:If this (or something similar) solves your problem, please create a ticket.