[Django]-Are there any plans to officially support Django with IIS?

4đź‘Ť

Django is WSGI-based framework so as soon as IIS get proper WSGI handling there should be no problem in running Django under this environment. Anything that connects WSGI and IIS will do.

Quick googling reveals some project on Google Code.

👤zgoda

4đź‘Ť

Take a look at Helicon Zoo—native fast IIS 7 module to run Python/Django applications.

Great article about it: Running Django on Windows.

👤rukeba

2đź‘Ť

There is another (faster) alternative for direct integration with IIS via WSGI: PyISAPIe.

isapi-wsgi is based from the relatively outdated ISAPI module included with Python and doesn’t mesh well with the design of IIS6/7. FastCGI is out-of-process and requires an IPC connection to IIS. Basic CGI means reloading Python for every request.

Also, PyISAPIe has a lower-level interface for those who prefer performance over compatibility.

👤Phillip

1đź‘Ť

I was fishing around for some info on the same topic. I found a project on codeplex that Jeff Hardy had implemented the WSGI interface on .net – NWSGI. He also has some entries on his blogs on specifically running DJANGO and IronPython.

Blogs: http://jdhardy.blogspot.com/search/label/Django

NWSGI Project: http://nwsgi.codeplex.com/

👤Ameer

1đź‘Ť

I know this isn’t the answer you’re looking for, but hopefully it can help someone else!

I’ve posted a Django on Windows 2008 tutorial/howto on my blog which you may find helpful.

After a few hours of trying to get Django running on IIS7 using PyISAPIe, I gave up, since I was getting this (difficult to diagnose) error code when visiting the site’s URL:

PyISAPIe
0x8007007e

Apparently, this also happens with the PHP ISAP (which apparently indicates a missing DLL dependency), so it could be the same problem as I’m having with PyISAPIe. Also, when I tried to install using the installer, I got some error about a missing DLL so it sounds logical.

Anyway, suffice to say, it looks like Django+IIS isn’t that popular, so the support doesn’t appear to be excellent…

The server has an additional IP address, so now I’m just going to run Apache along side IIS7, since there are some .Net apps running on the server.

Side note: To run IIS7 and Apache at the same time, you’ll need to tell IIS7 to only bind to one IP address.

Update: Just got Django working on Windows Server 2008! It’s running on Apache along side an existing IIS7 install (which is bound to only one IP), and seems to work just fine… And, I’d recommend this route, rather than trying to get IIS7 to play nice with Django – trust me, you’ll have a better time of it.

👤Nick Bolton

0đź‘Ť

You should be able to use the FastCGI isapi developed by MS. It works on 6 but has better integration on 7. Disclaimer: I haven’t tried it with Django.

👤Sam Corder

0đź‘Ť

“official” support is usually not provided for anything but products and languages created by Microsoft.

👤iisguy

0đź‘Ť

As for the “official” bit… Since Django 1.0 (and newer) are all-WSGI compliant, it will not surprise me if the WSGI at some time will become the only “official” deployment method. Since mod_python is deprecated (and not developed anymore) and FastCGI is really served by FCGI-to-WSGI gateway, this seems reasonable prediction.

👤zgoda

Leave a comment