-1

I want to know how do u host a website via jboss5.0.0

say i have my application on localhost

http:// localhost:8080/someApp

I want to point it to http:// www.someapp.com

Editing the server.xml i changed the port to 80 so the app is now on

http:// localhost/someApp

Now, i wrote the jboss-web.xml and changed the context root to /

<jboss-web> 
    <context-root>/</context-root> 
    <virtual-host>www.someapp.com</virtual-host> 
</jboss-web>  

and deleted the ROOT.war so the app is now on

http:// localhost/

So i if i now have have to put it up on say:

http:// www.someapp.com

What is the virtual host stuff ?

?

Regards,

Jamshed Katta

jamshed Katta
  • 73
  • 1
  • 9

1 Answers1

1

C:\jboss-5.1.0.GA\server\default\deploy\jbossweb.sar\server.xml

Go to the end of that file, there is a host tag, add this host tag after that.

<Host name="www.someapp.com" autoDeploy="false" deployOnStartup="false" deployXML="false">
 <Valve className="org.apache.catalina.valves.AccessLogValve" prefix="localhost_access_log." 
suffix=".log" pattern="common" directory="${jboss.server.log.dir}" resolveHosts="false"/>
</Host>

If you don't have DNS, you have to edit your hosts file to add the domain IP mapping.

http://www.openscope.net/2010/01/17/virtual-hosting-with-jboss/

Jon
  • 2,932
  • 2
  • 23
  • 30