Date: Wed, 28 Nov 2012 12:13:21 -0800 From: Marc Fournier <mfournier@sd63.bc.ca> To: freebsd-java@freebsd.org Subject: =?windows-1252?Q?=5BSOLVED=5D_Was=3A_Re=3A_Mapping_/_-=3E_jboss?= =?windows-1252?Q?=3A/application_in_Apache_=85?= Message-ID: <DB7C0A08-A96D-41B9-BEDB-4A1C4FF6C857@sd63.bc.ca> In-Reply-To: <2499889.49.1354126926241.JavaMail.mfournier@Marcs-Mac-Pro.local> References: <2499889.49.1354126926241.JavaMail.mfournier@Marcs-Mac-Pro.local>
next in thread | previous in thread | raw e-mail | index | archive | help
Figured it out =85 much simpler (at least then I was able to find) then = under Tomcat =85 Step 1: Edit standalone.xml to change enable-welcome-root to false: From: <virtual-server name=3D"default-host" = enable-welcome-root=3D"true"> <alias name=3D"localhost"/> <alias name=3D"example.com"/> </virtual-server> to: <virtual-server name=3D"default-host" = enable-welcome-root=3D"false"> <alias name=3D"localhost"/> <alias name=3D"example.com"/> </virtual-server> And then add a file jboss-web.xml to your .war file's WEB-INF directory = that contains: <?xml version=3D"1.0" encoding=3D"UTF-8"?> <jboss-web xmlns=3D"http://www.jboss.com/xml/ns/javaee" = xmlns:xsi=3D"http://www.w3.org/2001/XMLSchema-instance" = xsi:schemaLocation=3D" http://www.jboss.com/xml/ns/javaee = http://www.jboss.org/j2ee/schema/jboss-web_5_1.xsd"> <context-root>/</context-root> </jboss-web> And you are away to races =85 On 2012-11-28, at 10:22 , Marc Fournier <mfournier@sd63.bc.ca> wrote: >=20 > What is the currently recommended way to do this? I'm trying = proxy_ajp in Apache 2.2, since it seems the simplist to setup, and = reduces the # of modules I need to support ... but if I do something = like: >=20 > ProxyPass / ajp://localhost:8009/subfolder > ProxyPassReverse / ajp://localhost:8009/subfolder >=20 > When I go to: >=20 > http://localhost >=20 > the url gets rewritten as 'http://localhost/subfolder >=20 > and I get an error: >=20 > HTTP Status 404 - /subfoldersubfolder/ >=20 > from jboss ... >=20 > I want the whole /subfolder to be hidden behind the scenes, since this = is the only thing being served from that server, and adding /subfolder/ = just makes the URL longer then it needs to be ... >=20 > Is this a problem with using Apache2.2/proxy_ajp itself, or how I'm = setting up the proxy stuff ... ? If its with Apache2.2, would using = mod_jk fix it? >=20 > Or, should I just change the context-path in jboss to re-point :8080/ = and do / on Apache -> :8080/ on jboss ... ? >=20 > Thoughts / advice? >=20 > thanks ... >=20 >=20 >=20 >=20
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?DB7C0A08-A96D-41B9-BEDB-4A1C4FF6C857>