From DreamHost
Jump to: navigation, search
DreamHost does not directly support any of the features described on this page and is not responsible for keeping this content updated or accurate. Use at your own risk!
There may be additional information on the talk page.
This article or section contains conversational writing that requires cleanup.
All user comments should be confined to talk pages, and writing should not be done from the perspective of the author.
We are hoping to create articles that meet certain standards. Please discuss this issue on the talk page. Editing help is available.


Make sure you don't miss the part about compiling python with ./configure --prefix=$HOME/lib --enable-unicode=ucs4

I think you will also need AddDefaultCharset utf-8 in your .htaccess file.

Also if you are using sqlite make sure you have the bzip headers in your lib path. I did this by ./configure --enable-unicode=ucs4 --prefix=$HOME --with-bz2=$HOME/lib/ after I installed the headers.

From another post, you need to make sure your tg-fastcgi.fcgi is not group writeable, chmod 755 tg-fastcgi.fcgi

Last part for me to get it running was replacing this code in tg-fastcgi.fcgi. Make sure you replace wiki20 with your app.

   if exists(join(code_dir, "setup.py")):
       cherrypy.config.update(file=join(code_dir, "devcfg.py"))
       cherrypy.config.update(file=join(code_dir, "prodcfg.py")) 


   if exists(join(dirname(__file__), "setup.py")):

This is from my experiences, as of right now it appears to be working. If you have any changes please make them. Any questions contact me at jenocin at jenotek dot com.

--Jenocin 20:55, 3 Oct 2006 (PDT)

Improving TurboGears on Dreamhost

There are now two suggestions up on the Suggestions sections of the panel:

These two would benefit deployment and use of TurboGears -- there's a problem w/ restarting processes correctly when deploying using FastCGI, plus the memory consumption is 3x as large (with three forked processes as the current configuration on server glass).

Killed incorrectly, you'll have to wait for a couple of minutes (I *think* it's the Apache FastCGI timeout) before the application will start again. Also, the fact that you run N forked servers will force you to store all data in a database instead of keeping the state in the server, which is one of the main points of having an application server -- you have *state*.

Furthermore, having these two suggestions implemented would help Django and other frameworks that use application servers (as opposed to PHP which is really just a glorified CGI, i.e., stateless). Some other web hosts (linked from the TurboGears official site) assign port numbers to apps/websites to which the app is connected using an (optional) autostart CGI, bootstraping the app server, through a reverse proxy using Apache/mod_proxy. Very easy and very clever. Would be nice to see something similar at DreamHost.