Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jetty-users] Virtual Host configuration

Thanks again! As I wrote to Lachlan Roberts, the dual hosting now works as I hoped it would. Just wanted to make sure you saw this as well. Details are on the reply to Lachlan.



-----Original Message-----
From: Peter Boughton <jetty@xxxxxxxxxxxxxxxxx>
To: jetty-users@xxxxxxxxxxx
Sent: Fri, Jun 26, 2020 3:05 am
Subject: Re: [jetty-users] Virtual Host configuration

On 26/06/2020 05:06, philfrei@xxxxxxx wrote:
> I can get the browser to display the desired content by adding /hexara
> or /adonax to any of the four urls. But I'm hoping to eventually get to
> where the browser address bar displays the url and the browser screen
> shows the index.htm for that domain, with no need to add the /hexara or
> /adonax.

This is controlled by the contextPath setting - when on a single
hostname it's necessary to distinguish different contexts with a prefix,
but when the hostname decides the context it's rarely needed.

Either set contextPath to / or just remove that setting entirely.

> I was inspecting WebAppContext and didn't see a reference to a method
> setResourcePath in the api, but did spot setResourceBase in a parent
> class ContextHandler. On the chance the terms "path" and "base" were
> accidentally mixed up, I tested using <Set name="resourceBase">

Yep, it definitely should have been resourceBase not resourcePath, sorry
for confusion. :(

Next time I'll make sure to copy from a working config instead of
re-typing stuff.

jetty-users mailing list
To unsubscribe from this list, visit

Back to the top