0
正在使用Apache面前的Jboss App服务器。我的应用程序“测试”部署在Jboss中,并且使用mod_jk将apache安装到Jboss。我访问我的应用程序作为例子https://example.com/Test evrything工作正常。 但我目前的需求,它通过URL示例https://example.com/访问该应用程序,我不想使用上下文根。 请建议我如何实现相同。接受没有上下文根的应用程序URL
正在使用Apache面前的Jboss App服务器。我的应用程序“测试”部署在Jboss中,并且使用mod_jk将apache安装到Jboss。我访问我的应用程序作为例子https://example.com/Test evrything工作正常。 但我目前的需求,它通过URL示例https://example.com/访问该应用程序,我不想使用上下文根。 请建议我如何实现相同。接受没有上下文根的应用程序URL
对于战争,您需要使用jboss-web.xml
。对于EAR,您可以使用application.xml
。
的jboss-web.xml
看起来是这样的:
<?xml version="1.0" encoding="UTF-8"?>
<jboss-web xmlns="http://www.jboss.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.jboss.com/xml/ns/javaee http://www.jboss.org/j2ee/schema/jboss-web_5_1.xsd">
<context-root>/</context-root>
</jboss-web>