Can't Run Apache2 With Virtualenv
I'm making a website based on Django, on the server was installed a Python 3.5, but my project requires a Python 3.6. I decided to use virtualenv. I successfuly installed needed ve
Solution 1:
The mod_wsgi module is C code which links to the Python library. Thus the version of Python it is compiled for is embedded in the module. It doesn't just execute python
program. This means it has to be compiled for the version of Python you want to use. You cannot force it via a virtual environment to use a different Python version. This is stated in the documentation on using mod_wsgi with virtual environments.
In short, you need to uninstall the mod_wsgi module (likely the operating system packaged one), and install mod_wsgi yourself from source code, compiling it against the Python version you want to use. Easiest way of doing that is to use pip install
method.
Post a Comment for "Can't Run Apache2 With Virtualenv"