thanks for the pointers for mod_wsgi. I will have to use it for a limited distribution project, but for general use I still like using paster with supervisord
Graham Dumpleton wrote: > > On Mar 29, 8:42 am, jose <jj.gal...@gmail.com> wrote: > >> HI all, Just thought I would share what I've learned deploying pylons >> on both windows and linux loxes. First let me say right off the bat I >> absolutely love pylons I think hands down its the absolutely best web >> development environment out there. Having said that the biggest issue >> I see with pylons and wsgi apps in general, really has nothing to do >> with their ability to function as a framework, but its deployment. >> Now before anyone goes all "read the wiki" "read the docs" on me, I >> have so the rest of this is just my experience setting up pylons to >> run with Apache on both windows and linux (Ubuntu specifically). Now >> I love choices and if you want to connect your new pylons app to run >> under apache you do have several,mod_wsgi, fastcgi, scgi, mod_python, >> and the ever present mod_proxy, and I've tried them all. For my >> money, both in terms of simplicity and in terms of development cycles >> mod_proxy is by far the easiest and I would venture to say the most >> stable. I did usemod_wsgifor a while, and will most likely use it >> on a limited project where running a pylons long running appp will be >> problematic, but mod_proxy just offers so much in the way of >> flexibility. Not to mention the fact that I just hate restarting >> apache just because I've made some minor change to one of my >> controllers. >> > > If you think you have to restart Apache whenever making changes you > haven't delved into the documentation for mod_wsgi well enough. > > http://code.google.com/p/modwsgi/wiki/ReloadingSourceCode > > http://blog.dscpl.com.au/2008/12/using-modwsgi-when-developing-django.html > http://blog.dscpl.com.au/2009/02/source-code-reloading-with-modwsgi-on.html > > Graham > > >> So this brings me to the heart of what I've learned, if you are going >> to deploy a long running app how do you do it? On Windows the best >> solution I've come up with is my own Bourbon project, which I admit >> has all but died (I would love to give the code to someone to run >> with, I just really don't have the time to maintain it any longer). >> The reason I wrote it in the first place was allow give me a single >> windows service to manage all my running pylons apps without having to >> give each and every one its own windows service, which is a pain. >> Bourbon works pretty good, but at the moment you can't turn off or >> restart a single app, its all or nothing, which isn't very good. >> >> On Linux its a different story, there are a tun of ways to get a long >> running application up and running, and to some extent it depends on >> what distro you are using as to which is the best. On ubuntu I >> initially thought of writing rc init scripts for each app, but this >> quickly turned into a task that I didn't want to deal with, so I >> turned tomod_wsgi, which as I stated above for philosophical reasons >> I just didn't like. The I found, ok more likely stumbled upon after >> reading the wiki, supervisord. Finally something that makes sense (at >> least to me it really does). Now, after writing only a single rc init >> script to get supervisord running my pylons apps (and almost anything >> else I might have to start as a a daemon for that matter) is easily >> configured to run under the supervisord.conf file. I just love that >> thing. I know a best practices section goes against the grain for the >> pylons community because it is all about flexibility, but what about >> a series of deployment scenario's, where people could write how they >> are actually doing this stuff. I know its already all there if you >> look for it, but this has taken me while to put together for myself >> and I'm sure there are others out there who could learn from our >> growing pains >> > > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "pylons-discuss" group. To post to this group, send email to pylons-discuss@googlegroups.com To unsubscribe from this group, send email to pylons-discuss+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/pylons-discuss?hl=en -~----------~----~----~----~------~----~------~--~---