我已经在树脂应用程序服务器中部署了railo war文件,部署后jvm日志显示
railo-server-root:/var/resin/webapps/railo-4.2.1.008/WEB-INF/lib/railo-server
===================================================================
SERVER CONTEXT
-------------------------------------------------------------------
- config:/var/resin/webapps/railo-4.2.1.008/WEB-INF/lib/railo-server/context
- loader-version:4.3
===================================================================
===================================================================
WEB CONTEXT (3ccbecdfdd85a2c229a64e875ca4821a)
-------------------------------------------------------------------
- config:/var/resin/webapps/railo-4.2.1.008/WEB-INF/railo
- webroot:/var/resin/webapps/railo-4.2.1.008/
- hash:3ccbecdfdd85a2c229a64e875ca4821a
- label:3ccbecdfdd85a2c229a64e875ca4821a
===================================================================
我可以通过调用访问.cfm保存在/var/resin/webapps/railo-4.2.1.008/index .cfm http://domain.com:8080/railo/index.cfm
但是当我尝试访问 http://domain.com:8080/railo/railo-context/admin/server.cfm 或 http://domain.com:8080/railo/railo-context/admin/web.cfm.它正在加载一个没有 css 等的页面。
我还在日志中看到以下错误 星期三 十一月 19 02:15:51 EST 2014-311 类 railo.runtime.instrumentation.Agent.getInstrumentation() 不返回检测 找不到静态资源/railo-context/res/css/admin42.css.cfm @/var/resin/webapps/railo-4.2.1.008/-context/res/css/admin42.css 找不到静态资源/railo-context/res/css/admin42.css.cfm @/var/resin/webapps/railo-4.2.1.008/-context/res/css/admin42.css 找不到静态资源/railo-context/res/css/admin42.css.cfm @/var/resin/webapps/railo-4.2.1.008/-context/res/css/admin42.css
我做错了什么
在您的网址中 domain.com:8080/railo/railo-context/...第一个 railo 是上下文路径吗? 基本上,您是否部署了 Railo 战争但不是在/上下文中?
如果是这样,您可能需要修改 railo-server.xml 文件中的/railo-context/虚拟映射以映射到 "/railo/railo-context/"
此外,请检查设置的任何重写规则。
Railo(不确定哪个版本,但 4.x 版本之一)将管理员资源(即图像)移出与管理员其余部分相同的文件夹.css这意味着它们不再处于/railo-context/
中,他们现在使用 ../res/bar.css
等路径来加载它们。
我们的解决方法是为另一个目录添加代理/重写。例如:
ProxyPassMatch ^/my-secret-railo-location/admin/(.*)$ ajp://localhost:8009/railo-context/admin/$1
ProxyPassMatch ^/my-secret-railo-location/res/(.*)$ ajp://localhost:8009/railo-context/res/$1