Jetty: adding a simple documents directory
Par cyril le jeudi 7 mars 2013, 18:19 - Lien permanent
When deploying OpenIDM, you may wish to add your own HTML static pages to
the default Jetty container. Suppose for example you want to add a /help
documents directory. One of the easiest way to do so is to add the following
lines to your jetty.xml configuration file:
<Set name="handler">
<New class="org.eclipse.jetty.server.handler.HandlerList">
<Set name="handlers">
<Array type="org.eclipse.jetty.server.Handler">
<Item>
<New class="org.eclipse.jetty.server.handler.ContextHandler">
<Set name="contextPath">/help</Set>
<Set name="handler">
<New class="org.eclipse.jetty.server.handler.ResourceHandler">
<Set name="directoriesListed">false</Set>
<Set name="resourceBase">./my_help_docs_directory</Set>
</New>
</Set>
</New>
</Item>
</Array>
</Set>
</New>
</Set>
So simple !