<?xml version="1.0"  encoding="ISO-8859-1"?>
<!DOCTYPE Configure PUBLIC "-//Jetty//Configure//EN" "http://www.eclipse.org/jetty/configure.dtd">

<!--
Configure a custom context for the eepsite.

This context contains only a ServletContextHandler with a default servlet
to serve static html files and images.
-->

<Configure class="org.eclipse.jetty.servlet.ServletContextHandler">
  <Set name="contextPath">/</Set>
  <Set name="resourceBase">./eepsite/docroot/</Set>
  <!-- change to false to disallow directory listings -->
  <Call name="setInitParameter">
    <Arg>org.eclipse.jetty.servlet.Default.dirAllowed</Arg>
    <Arg>true</Arg>
  </Call>
  <Call name="setInitParameter">
    <Arg>org.eclipse.jetty.servlet.Default.stylesheet</Arg>
    <Arg>./eepsite/docroot/.resources/jetty-dir.css</Arg>
  </Call>
  <Call name="setMimeTypes">
    <Arg>
      <New class="org.eclipse.jetty.http.MimeTypes">
        <Call name="addMimeMapping">
          <Arg>sud</Arg>
          <Arg>application/zip</Arg>
        </Call>
        <Call name="addMimeMapping">
          <Arg>su2</Arg>
          <Arg>application/zip</Arg>
        </Call>
        <Call name="addMimeMapping">
          <Arg>xpi2p</Arg>
          <Arg>application/zip</Arg>
        </Call>
      </New>
    </Arg>
  </Call>
  <Call name="addServlet">
    <Arg>net.i2p.servlet.I2PDefaultServlet</Arg>
    <Arg>/</Arg>
    <!-- set to false to disable the last-modified (utc) header -->
    <Call name="setInitParameter">
      <Arg>setLastModifiedHeader</Arg>
      <Arg>true</Arg>
    </Call>
  </Call>
</Configure>

