I am trying to deploy Django rest framework on my Debian 10 server.I am using Apache2 but he keeps crashing because its not using the right python version.
I am using python3.12 version for my project :
python --versionPython 3.12.2But Apache2 is running with python3.7 so its crashing because it cant find Django Module
Apache/2.4.38 (Debian) mod_wsgi/4.6.5 Python/3.7 configured I tried to install mod_wsgi with pip but I keep getting this error :
/usr/bin/ld: final link failed: nonrepresentable section on output collect2: error: ld returned 1 exit status error: command '/usr/bin/gcc' failed with exit code 1 [end of output] note: This error originates from a subprocess, and is likely not a problem with pip. ERROR: Failed building wheel for mod_wsgiFailed to build mod_wsgiERROR: Could not build wheels for mod_wsgi, which is required to install pyproject.toml-based projectsThanks to everyone fo your time !
I tried everything I found on existing topics.
I am expecting a solution to be able to install mod_wsgi and use the right python version on my apache2 server