On Jul 24, 5:48 am, Leonardo Santagada <santag...@gmail.com> wrote:
> On Thu, Jul 23, 2009 at 3:26 PM, Olemis Lang <ole...@gmail.com> wrote:
>
> > On Thu, Jul 23, 2009 at 1:06 PM, Leonardo Santagada<santag...@gmail.com>
> > wrote:
>
> > > On Thu, Jul 23, 2009 at 2:45 PM, Olemis Lang <ole...@gmail.com> wrote:
>
> > >> Hello !
>
> > >> I'd like to try TracWsgi plugin but there's something I dont understand
> > :
>
> > >> - Does it work with any HTTP server ?
>
> > > Yes. Theres mod_wsgi for apache and ngix and FastCGI for those http
> > servers
> > > and others
>
> > So this means that I cannot use Trac on top of `mod_python` and then
> > run the WSGI app on top of Trac. Isn't it?
>
> > I forgot to mention something here . I want to run an app inside Trac
> > URL space, not Trac using PasteDeploy script ... ;)
>
> > Here I'd like to know something. How does it work ? The two
> > alternatives I have in mind are the following :
>
> > - The plugin acts as a wrapper and uses the Trac web context to
> > «rewrite» the WSGI environment used to run the «inner» app .
>
> > - The hosted app is run by the app server directly.
>
> > Which one is correct ? With my eyes closed I thought it was the first
> > one and in this case I supposed that only trac.ini had to be modified,
> > but I'm not sure.
>
> > Ahhhh ! I assume that I need PasteDeploy . Is it correct ?
>
> > >> - I mean, suppose I've installed and setup Trac already : The only
> > >> thing I need to do
> > >> in order to run a WSGI app is to modify `trac.ini` by including
> > >> PasteDeploy config
> > >> options ? Should I do anything else ?
>
> > > configure your http server for serving a wsgi app.
>
> > Well is it when Trac is deployed using PasteDeploy, or when the plugin
> > is used to run WSGI apps inside Trac, or both ? (yes I didnt say what
> > I wanted to do before :-/ )
>
> I never used this plugin in particular, but if I read the documentation
> corretly it does two thing, serve trac as a wsgi app (which can be done
> without a plugin) and permits wsgi apps to be served in the same urlspace as
> trac. Probably its easy to find in the code how it does this, my guess would
> be that it redirect requests from trac otherwise it wouldn't need to be a
> trac plugin, but I'm only guessing.
Not sure the original poster is clear enough about what he wants to
do.
If all he wants to do is mount two distinct WSGI applications, ie.,
Trac and something else, at different mount points of the same server,
then he can use mod_wsgi. Eg.
WSGIScriptAlias /inner /some/path/inner.wsgi
WSGIScriptAlias / /some/path/trac.wsgi
When doing this, mod_wsgi will ensure that WSGI environment is correct
for the respective mount points.
If he wants to actually have the Trac application modify the WSGI
request environment or request content stream on the way in, or have
the Trac application modify response headers of response content
stream on the way out, or use a form based authentication mechanism in
Trac to control access to the inner application, then he would need to
use a form of object composition.
So, what is it?
Graham
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Trac
Users" group.
To post to this group, send email to trac-users@googlegroups.com
To unsubscribe from this group, send email to
trac-users+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/trac-users?hl=en
-~----------~----~----~----~------~----~------~--~---