Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[jetty-users] sharing config across servers in jetty 9

I have 10 or so webapps that I want to run on N jetty servers, (each server in their own JVM with one or two webapps per server). I would like the servers to share the same jetty.home (unmodified jetty installation). The servers will be similar in terms of having the same modules enabled and similar config so I would like to share that config as well. Each server would have its own webapps folder and logs directory and it would be nice if they could have a start.d and etc directories and start.ini file to override shared properties and configuration so that would argue for setting the jetty.base as the server directory. Under that scenario I don't see a way to reference shared config without modifying the files in jetty.root (when using start.jar). If I make the jetty.base point to the shared config then I could pass in properties and xml config as command-line arguments for server specific overrides but then I would need to customize several modules to give each server its own webapps and logs folder since the modules seem to assume jetty.base is not shared by multiple JVMs running jetty. 

Maybe what I should be doing is just putting my shared config in jetty.root so that when I upgrade to a new distro I can just unzip the shared config on top of the new distro. Another option would be to put shared config in version control in one place and just deploy multiple copies of the shared config in each server's base directory. 

What I think would be ideal is the ability to have multiple jetty.root folders where the first one would be the full jetty distro and each subsequent one could add or override files in the start.d, etc, modules and resources folders. 

ex. jetty.root=/opt/jetty-distribution-9.1.3.v20140225,/opt/jetty-shared

Am I missing a way to set this up with a clean jetty.root and config shared by multiple jetty servers?

Thanks, Hal

Back to the top