Django

Code

Ticket #135 (closed: fixed)

Opened 3 years ago

Last modified 2 years ago

Document mod_python behavior with more than one SETTINGS in a vhost

Reported by: Manuzhai Assigned to: jacob
Milestone: Component: Documentation
Version: Keywords:
Cc: Triage Stage: Unreviewed
Has patch: 0 Needs documentation: 0
Needs tests: 0 Patch needs improvement: 0

Description

URL resolving will be unstable if more than one DJANGO_SETTINGS_MODULE is referenced within a vhost (for example, in different locations) due to mod_python caching. This should be documented in the mod_python doc.

Attachments

Change History

07/21/05 10:40:34 changed by adrian

  • status changed from new to closed.
  • resolution set to fixed.

(In [275]) Fixed #135 -- Added 'Multiple Django installations on the same Apache' to docs/mod_python.txt

07/21/05 11:29:56 changed by mfenniak@pobox.com

I believe this can be addressed by using mod_python's PythonInterpreter directive. This can force mod_python to use seperate python interpreter instances. For example:

<Location "/">
    SetHandler python-program
    PythonHandler django.core.handlers.modpython
    SetEnv DJANGO_SETTINGS_MODULE mysite.settings.main
    ...
    PythonInterpreter mysite.main
</Location>

<Location "/admin">
    SetHandler python-program
    PythonHandler django.core.handlers.modpython
    SetEnv DJANGO_SETTINGS_MODULE mysite.settings.admin
    ...
    PythonInterpreter mysite.admin
</Location>

This configuration seems to work for me. The PythonInterpreter directive is documented at http://www.dusek.ch/manual/apache/mod_python/dir-other-pi.html.

07/21/05 11:40:46 changed by anonymous

  • status changed from closed to reopened.
  • resolution deleted.

07/22/05 13:04:16 changed by adrian

  • status changed from reopened to closed.
  • resolution set to fixed.

Fixed in [277].


Add/Change #135 (Document mod_python behavior with more than one SETTINGS in a vhost)




Change Properties
Action