I am using Linux, yep.
Right now I am running with the standard default settings of mod_wsgi and
just added those lines in the apache-site-config:
<Directory /var/www/myDomain.com/web>
Options -Indexes -MultiViews +FollowSymLinks +ExecCGI
AllowOverride All
DirectoryIndex index.py
AddHandler wsgi-script .py
WSGIPythonPath /path/to/my/custom/stuff
WSGIApplicationGroup %{GLOBAL}
Order allow,deny
Allow from all
</Directory>
That's it.
Also, right now I do have the python script just in my DocumentsRoot folder
and am accessing it directly via browser.. no WSGIScriptAlias.
When looking at the sys.path now in my script, the "/path/to/my/custom/stuff"
is not there.. :(
Cheers,
Daniela
On Thursday, November 6, 2014 11:35:07 PM UTC-8, Graham Dumpleton wrote:
>
>
> On 07/11/2014, at 6:27 PM, Daniela Hase <[email protected]
> <javascript:>> wrote:
>
> Hi,
>
> I am using mod_wsgi on a couple of my sites and assigned them all to the
> global ApplicationGroup:
>
>
> <Directory /var/www/myDomain.com/web>
> # ...
> WSGIApplicationGroup %{GLOBAL}
> </Directory>
>
>
> I was wondering, is it now possible to define a custom PythonPath for each
> of my sites?
>
> I tried WSGIPythonPath, but this doesn't seem to work.. at least, when I
> look at the sys.path from within one of my applications, the path I defined
> with WSGIPythonPath doesn't show up.
>
> Or is the only way to have different python paths for each site to use the
> Daemon mode?
>
>
> Can you show more of the configuration such that can see WSGIScriptAlias,
> WSGIPythonPath and where/how you are using them all together.
>
> You mention daemon mode, but can you confirm you are not on Windows.
>
> Also confirm that you don't have mod_python loaded into the same Apache
> instance.
>
> WSGIPythonPath should work if it is referring to valid directories, so
> seeing the whole configuration related to the WSGI site would help.
>
> Graham
>
>
--
You received this message because you are subscribed to the Google Groups
"modwsgi" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/modwsgi.
For more options, visit https://groups.google.com/d/optout.