Running Pylons via FastCGI (Again)

2007-09-10 Thread [EMAIL PROTECTED]
Hello, I am trying to test Pylons on my hosting provider just using the default Pylons project. This is my FastCGI script: #!/home//local/bin/python from paste.deploy import loadapp from fcgi import WSGIServer app = loadapp('config:/home///development.ini') server = WSGIServer(app) server.run

Re: Running Pylons via FastCGI (Again)

2007-09-10 Thread [EMAIL PROTECTED]
Issuing an os.chdir(/path/to/pylons) fixed the problem although I am not sure if this is the best solution or not. If there any suggestions on how to make this work better, I would really appreciate it. Thanks! --~--~-~--~~~---~--~~ You received this message beca

Re: Running Pylons via FastCGI (Again)

2007-09-11 Thread Jens Hoffrichter
Hello, On 9/11/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > Issuing an os.chdir(/path/to/pylons) fixed the problem although I am > not sure if this is the best solution or not. If there any suggestions > on how to make this work better, I would really appreciate it. I think you need to a

Re: Running Pylons via FastCGI (Again)

2007-09-11 Thread [EMAIL PROTECTED]
On Sep 11, 4:57 am, "Jens Hoffrichter" <[EMAIL PROTECTED]> wrote: > I think you need to add the pylons path to the library paths in python. > > I normally do something like this: > > import sys > > sys.path = I had done that: pkg_resources.working_set.add_entry('/path/to/pylons') sys.path.append

Re: Running Pylons via FastCGI (Again)

2007-09-11 Thread Jens Hoffrichter
Oops, when I just saw this posting, I saw that somehow half the message was truncated. Don't know how that happened It should read: import sys sys.path = [ sys.path[0], '/path/to/pylons'] + sys.path[1:] That does the trick for me in normal python applications, it should work in pylons as w