Windows Web Deployment:

Everything you wanted to know,
but were to horrified to ask!

Christopher Lambacher
KCL Custom Software

Why would you subject yourself to this torture?

You like pain!

You want to be different than the cool Python kids?

Your IT department tells you that this is a MICROSOFT shop?

You have 200,000 lines of Classic ASP that you need to port!

First Rule Of Deployment Club

Make your application work first,
then work on deployment!

Deployment Models

  • Embed in Web Server
  • Reverse Proxy
  • Expose your development server

Web Servers

  • Front End
  • WSGI

Front End

  • IIS
  • Apache


  • Paste serve (no Python 3)
  • Waitress
  • CherryPy
  • Twisted (no Python 3… yet)
  • POSIX only:

Embed In Server Deployment

  • Web server manages processes
  • Web server manages communication
  • Lower communication overhead (maybe)



Reverse proxy

  • Load balancing with multiple processes
  • Merge multiple applications into one
  • Greater process and threading model control


Comes Fully Loaded


Needs Some Help

Windows Services

Pure Python
Console Application Wrappers




  • pip
    • only installs packages from source, so you also need a compiler
    • wheel package format may fix that soon
  • easy_install
    • has fewer niceties, but supports binary packages
    • will work for now!
  • Be careful about combining pip and easy_install, they handle namespace packages differently and can get in each others way


  • py2exe gives you an executable that runs one Python program
  • Does not always play nice setuptools/distribute and entry points
  • Avoid problems by putting your package on the file system and not in the provided


Temporary Key Value Stores

  • This is one of the harder problems to solve…
  • Memcached is installed as part of a Couchbase install, but it is essential to do connection pooling on a high traffic site
  • Redis has no production ready Windows support
  • We Use Redis in a Linux VM, hosted on a Windows server


Christopher Lambacher
KCL Custom Software

Extra Resources

Picture Credits

  • Tough Cat Eats Pain For Breakfast:
  • One Of These Things Is Not Like The Others:
  • Microsoft Store:
  • Old Dog New Tricks Philosoraptor:
  • I Don't Always Deploy Software:

More Picture Credits

  • Crazy Swiss Army Knife:
  • The One Ring:
  • Problems:
  • Tux Fork:
  • It's A Trap: