Cant serve static files
Left Right
olegsivokon at gmail.com
Fri Jan 31 15:45:37 UTC 2014
Sorry, I've copied the wrong log entry, this is the correct one:
127.0.0.1 - [2014-01-31 17:35:44] "GET /game.html HTTP/1.1" 404 188 "-"
"Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko)
Chrome/28.0.1500.95 Safari/537.36"
On Fri, Jan 31, 2014 at 5:33 PM, Oleg Sivokon <olegsivokon at gmail.com> wrote:
> Hello list,
>
> There should be something very simple I've overlooked, yet I can't find
> it. Hunchentoot seems not to be able to locate the root directory, where
> I have my static content, and I can't get it to print any useful
> information about it. That's why I'm asking for your help.
>
> Below is my setup:
>
> (setf (logical-pathname-translations "rgol")
> '(...
> ("WWW;*.*.*" "/home/wvxvw/.../www/")
> ("WWW;*;*.*.*" "/home/wvxvw/.../www/*")
> ...))
>
> (make-instance 'hunchentoot:acceptor :port 4242
> :document-root #p"rgol:www;"
> :message-log-destination #p"rgol:logs;messages.log"
> :access-log-destination #p"rgol:logs;access.log")
>
> I've defined another handler, which doesn't depend on static files, and
> it works fine, however, when I try to access static files, the log
> record looks like this:
>
> 127.0.0.1 - [2014-01-31 17:12:40]
> "GET /img/made-with-lisp-logo.jpg HTTP/1.1"
> 404 206 "http://localhost:4242/game.html"
> "Mozilla/5.0 (X11; Linux x86_64; rv:23.0) Gecko/20100101 Firefox/23.0"
>
> But the file is definitely there, because if I try this in REPL:
>
> (directory #p"rgol:www;*.*")
> (#P"/home/wvxvw/.../www/game.html"
> ... more files ...)
>
> My version of Hunchentoot is:
>
> hunchentoot:*hunchentoot-version*
> "1.2.17"
>
> $ sbcl --version
> SBCL 1.1.2-1.fc18
>
> Best,
>
> Oleg
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.common-lisp.net/pipermail/tbnl-devel/attachments/20140131/3bbd0788/attachment.html>
More information about the Tbnl-devel
mailing list