It is better to create mod_wsgi yourself from the code, rather than using an arbitrary binary file from the network. The steps are as follows.
Make sure you have a decent Apache installation that includes header files, such as Apache 2.4.37 Win64 from Apache Lounge . It is preferably installed in the C: /Apache24 .
Make sure your Python installation is configured so that you can install pip modules. This should include the correct Microsoft C compiler required for this version of Python.
Run pip install mod_wsgi . If your Apache installation is not in C: /Apache24 , first set the MOD_WSGI_APACHE_ROOTDIR environment variable for MOD_WSGI_APACHE_ROOTDIR . Make sure you specify the path in the form C: /Apache24 and not with a backslash, that is, not like C:\Apache24 . This is only necessary during installation, and not later.
Run mod_wsgi-express module-config .
Copy the output from mod_wsgi-express module-config to the Apache configuration file.
Add the configuration for the WSGI application to the Apache configuration.
Restart Apache and see if it works.
Note that you'd better start with the WSGI hello world, and not with some huge Django app during initial testing.
source share