This file is indexed.

/usr/share/doc/libghc-servant-server-doc/html/Servant-Utils-StaticFiles.html is in libghc-servant-server-doc 0.8.1-2.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Servant.Utils.StaticFiles</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script src="file:///usr/share/javascript/mathjax/MathJax.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Servant-Utils-StaticFiles.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="src/Servant-Utils-StaticFiles.html">Source</a></li><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">servant-server-0.8.1: A family of combinators for defining webservices APIs and serving them</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell2010</td></tr></table><p class="caption">Servant.Utils.StaticFiles</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>This module defines a sever-side handler that lets you serve static files.</p><ul><li><code><a href="Servant-Utils-StaticFiles.html#v:serveDirectory">serveDirectory</a></code> lets you serve anything that lives under a particular
   directory on your filesystem.</li></ul></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:serveDirectory">serveDirectory</a> :: <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.0.0/System-IO.html#t:FilePath">FilePath</a> -&gt; <a href="Servant-Server-Internal.html#t:Server">Server</a> <a href="file:///usr/share/doc/libghc-servant-doc/html/Servant-API-Raw.html#t:Raw">Raw</a></li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a id="v:serveDirectory" class="def">serveDirectory</a> :: <a href="file:///usr/share/doc/ghc-doc/html/libraries/base-4.9.0.0/System-IO.html#t:FilePath">FilePath</a> -&gt; <a href="Servant-Server-Internal.html#t:Server">Server</a> <a href="file:///usr/share/doc/libghc-servant-doc/html/Servant-API-Raw.html#t:Raw">Raw</a> <a href="src/Servant-Utils-StaticFiles.html#serveDirectory" class="link">Source</a> <a href="#v:serveDirectory" class="selflink">#</a></p><div class="doc"><p>Serve anything under the specified directory as a <code><a href="file:///usr/share/doc/libghc-servant-doc/html/Servant-API-Raw.html#t:Raw">Raw</a></code> endpoint.</p><pre>type MyApi = &quot;static&quot; :&gt; Raw

server :: Server MyApi
server = serveDirectory &quot;/var/www&quot;
</pre><p>would capture any request to <code>/static/&lt;something&gt;</code> and look for
 <code>&lt;something&gt;</code> under <code>/var/www</code>.</p><p>It will do its best to guess the MIME type for that file, based on the extension,
 and send an appropriate <em>Content-Type</em> header if possible.</p><p>If your goal is to serve HTML, CSS and Javascript files that use the rest of the API
 as a webapp backend, you will most likely not want the static files to be hidden
 behind a <em>/static/</em> prefix. In that case, remember to put the <code><a href="Servant-Utils-StaticFiles.html#v:serveDirectory">serveDirectory</a></code>
 handler in the last position, because <em>servant</em> will try to match the handlers
 in order.</p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.17.2</p></div></body></html>