Maybe try changing fastcgi.debug to 1 and check out the logs?

Sam.

On Nov 8, 8:21 am, cyberco <[EMAIL PROTECTED]> wrote:
> Unfortunately I keep getting the same error (see above, also the
> 'connection refused' error). The file 'code.py' is owned by the same
> user:group as any other file that is being served by the webserver. I
> am not sure whether the python file starts at all. I've put a print
> line at the very beginning that is not displayed, so I guess it's not
> starting. Could it maybe be a timeout issue? Since I'm running
> lighttpd on a severly limited device it may take too long to start the
> Python interperter. Running the web.py as a standalone script works
> fine though.
>
> Btw: The 'connection refused' error does not appear the first time I
> start lighttpd with a new name for  "socket" => "/tmp/
> lighttpd.code.fcgi.socket". That doesn't seem right to me.
>
> Below are the files I'm using.
>
> ===lighttpd.conf==================
> server.document-root = "/usr/www/lib/"
> server.errorlog = "/var/log/lighttpd/error.log"
> server.port = 80
> server.username = "www-data"
> server.groupname = "www-data"
> server.modules          = (
>                             "mod_access",
>                             "mod_alias",
>                             "mod_fastcgi",
> )
> server.errorfile-prefix = "/usr/www/lib/error-"
> mimetype.assign = (
>   ".html" => "text/html",
>   ".txt" => "text/plain",
>   ".jpg" => "image/jpeg",
>   ".png" => "image/png",
>   ".gif" => "image/gif",
>   ".css" => "text/css"
> )
> static-file.exclude-extensions = ( ".fcgi", ".php", ".rb", "~",
> ".inc", ".cgi")
> fastcgi.debug = 0
> fastcgi.server = (
>     "/code" =>
>      (( "socket" => "/tmp/lighttpd.code.fcgi.socket",
>         "bin-path" => "/usr/www/lib/code.py",
>         "check-local" => "disable",
>         "max-procs" => 1
>      ))
> )
>
> =====================
>
> ===code.py==================
> #!/usr/local/bin/python
> import web
>
> urls = (
>     '/(.*)', 'hello'
> )
>
> class hello:
>     def GET(self, name):
>         i = web.input(times=1)
>         if not name:
>             name = 'world'
>         for c in xrange(int(i.times)):
>             print 'Hi,', name+'!'
> =====================


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"web.py" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/webpy?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to