-
1. Re: To replace this page set "enable-welcome-root" to false in your server configuration and deploy your own war with / as its context path.
ctomc Nov 12, 2013 9:13 AM (in response to ajmercer)Hi,
there is no need for enable-welcome-root conf attribute anymore. Welcome page is disabled automatically when anything is deployed to '/' context.
We need to update that page to note it
With your configuration you should get your application bound to '/' only in case that your deployment is named exactly "railo01.war" otherwise it would not work.
if that does not work it is a bug, what exact version of WildFly do you use?
also you could add jboss-web.xml into your WEB-INF with content
<?xml version="1.0"?>
<jboss-web>
<context-root>/</context-root>
</jboss-web>
--
tomaz
-
2. Re: To replace this page set "enable-welcome-root" to false in your server configuration and deploy your own war with / as its context path.
ajmercer Nov 12, 2013 7:27 PM (in response to ctomc)I am running yesterdays nightly build - 8.0.0.Beta2-SNAPSHOT
I added C:\wildfly-8.0.0.Beta2-SNAPSHOT\bin\content\railo01.war\WEB-INF\jboss-web.xml with your content.
I did have this before with this as well
<virtual-host>services.dev.psl.com.au</virtual-host>
to match 'name' from standalone.xml
<host name="services.dev.am.com.au" alias="services.devam02.local" default-web-module="railo01.war" />
I have railo01.war deployed, and can access it at
services.devam02.local:8080/railo01/
But still no change.
I deliberately messed with the xml in jboss-web.xml - I was expecting to see eror messages
Where would these be logged?
How can I tell if jboss-web.xml is been read?
-
3. Re: To replace this page set "enable-welcome-root" to false in your server configuration and deploy your own war with / as its context path.
ctomc Nov 13, 2013 1:50 AM (in response to ajmercer)So which part of configure context-root did you not understand?
i am talking about context root, you are configuring virtual-host....
also why are you modifying content inside bin lib, that should be in standalone/deployments folder...
-
4. Re: To replace this page set "enable-welcome-root" to false in your server configuration and deploy your own war with / as its context path.
ajmercer Nov 13, 2013 2:25 AM (in response to ctomc)When I deploy a WAR (via web interface), that is where I found it.
If I drop the WAR file in
C:\wildfly-8.0.0.Beta2-SNAPSHOT\standalone\deployments
they also end up in
C:\wildfly-8.0.0.Beta2-SNAPSHOT\bin\content
My jboss-web.xml is exactly how you described ( no virtual-host).
What do I have to do so I can but this file in
C:\wildfly-8.0.0.Beta2-SNAPSHOT\standalone\deployments
directory?
-
5. Re: To replace this page set "enable-welcome-root" to false in your server configuration and deploy your own war with / as its context path.
fhpaul Nov 13, 2013 8:40 AM (in response to ajmercer)Hi,
I have a similar problem. The essential question is "How do I set up a virtual host for a default WebApp at context root in WildFly"? Obviously the configuration differs from JBoss7.
Please update the documentation for WildFly (Admin Guide - WildFly 8 - Project Documentation Editor).
Regards,
F.H.Paul
-
6. Re: To replace this page set "enable-welcome-root" to false in your server configuration and deploy your own war with / as its context path.
fhpaul Nov 13, 2013 9:58 AM (in response to ajmercer)Hi,
I got the virtual host with default web app at context root working on wildfly-8.0.0.Beta1 with the following configuration (the default-web-module attribute is supported again with beta1). I did not have to make changes regarding the "enable-welcome-root" flag.
Note: My browser played tricks with me and displayed the WildFly welcome page from cache, so F5 helped displaying my application after I configured WildFly and Apache the following way:
standalone.xml:
<server name="default-server">
<http-listener name="default" max-post-size="10485760" socket-binding="http"/>
<ajp-listener name="myListener" socket-binding="ajp"/>
<host name="default-host" alias="localhost">
<location name="/" handler="welcome-content"/>
</host>
<host name="my-virtual-host" alias="myapp.domain.org" default-web-module="mywebapp.war" />
</server>
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>
<virtual-host>my-virtual-host</virtual-host>
</jboss-web>
apache config:
<VirtualHost *:80>
ServerName myapp.domain.org
JkMount /* worker1
JkMount / worker1
</VirtualHost>
workers.properties:
worker.list=worker1
worker.worker1.host=localhost
worker.worker1.port=8009
worker.worker1.type=ajp13
jk.conf (mods-enabled):
JkWorkersFile "/etc/apache2/workers.properties"
Regards,
F.H.Paul
-
7. Re: To replace this page set "enable-welcome-root" to false in your server configuration and deploy your own war with / as its context path.
ajmercer Nov 13, 2013 5:31 PM (in response to fhpaul)What is the path to your 'jboss-web.xml' file?
Do you created it on the file system,
or should it be packaged within the WAR?
-
8. Re: To replace this page set "enable-welcome-root" to false in your server configuration and deploy your own war with / as its context path.
fhpaul Nov 14, 2013 2:48 AM (in response to ajmercer)jboss-web.xml is located in the WEB-INF directory and packaged within the WAR
-
9. Re: To replace this page set "enable-welcome-root" to false in your server configuration and deploy your own war with / as its context path.
ajmercer Nov 14, 2013 3:09 AM (in response to fhpaul)Makes sense, will try that.
Thanks