I want to set up a Spray route to serve web content out of a directory.
For example, the below URLs should resolve to the same file.
http://mywebsite.com/path/to/thing
http://mywebsite.com/path/to/thing/
http://mywebsite.com/path/to/thing/index.html
Should serve the index.html file from the filesystem at ./web/path/to/thing/index.html
The following route works if "index.html" is explicitly specified but not otherwise.
pathPrefix("") {
getFromDirectory("./web/")
}
How do i represent this in Spray routing?