title: How to deploy a Django/WSGI as an azure webapp with a different Python runtime?
body: <p>I'm trying to deploy a Django webapp on a Microsoft Azure webapp instance (it is a managed Windows VM). The documentation here,</p>
  
  <p><a href="https://docs.microsoft.com/en-us/azure/app-service-web/web-sites-python-configure" rel="nofollow noreferrer">https://docs.microsoft.com/en-us/azure/app-service-web/web-sites-python-configure</a></p>
  
  <p>describes how to deploy an application with either Python 2.7 or Python 3.4. I'm trying to deploy an app built with Python 3.6 (not a runtime supported by Azure out-of-box). I installed the runtime using the 'Site Extensions' feature of Azure. Here's the link to the extension (I think),</p>
  
  <p><a href="https://www.siteextensions.net/packages/python361x86/" rel="nofollow noreferrer">https://www.siteextensions.net/packages/python361x86/</a></p>
  
  <p>I primarily work on Linux systems using Apache. The difficulty I'm facing here is how to configure IIS on the Azure instance to use Python 3.6 to run my django webapp (it works on my development system using the runserver command). Sadly, I cannot request to use a Linux VM on azure (business constraint).</p>
  
  <p>One problem I'm having is how to write the <code>web.config</code> file on the project. The reference Python3.4 one uses a virtualenv which, oddly enough, is explicitly disabled on Python with site extensions ( ref: <a href="https://github.com/Azure/azure-python-siteextensions/issues/6" rel="nofollow noreferrer">https://github.com/Azure/azure-python-siteextensions/issues/6</a> ).</p>
  
  <p>Another issue I'm having is that I'd like to use waitress WSGI instead of FastCGI (ref: <a href="http://docs.pylonsproject.org/projects/waitress/en/latest/" rel="nofollow noreferrer">http://docs.pylonsproject.org/projects/waitress/en/latest/</a> ). </p>
  
  <p>Can someone point me to a <code>web.config</code> + <code>python wsgi script</code> combination which runs on azure using Python 3.6 ? Alternate suggestions are also welcome. </p>