https://www.rpatterson.net/Ross Patterson's Blog - Posts tagged fcgi2023-08-22T15:29:28.153182+00:00ABloghttps://www.rpatterson.net/blog/wsgi-apps-on-iis/WSGI apps on IIS2012-10-30T00:00:00+00:00Ross Patterson<section id="wsgi-apps-on-iis">
<blockquote>
<div><p>iiswsgi provides a WSGI server providing a FCGI gateway to IIS and setup.py commands for distributing apps as WebPI packages</p>
</div></blockquote>
<p>The <a class="reference external" href="https://github.com/rpatterson/iiswsgi">iiswsgi</a> module implements a FastCGI to <a class="reference external" href="http://wsgi.readthedocs.org/en/latest/">WSGI</a> gateway that
is compatible with <a class="reference external" href="http://www.iis.net">IIS</a>’s variation of the <a class="reference external" href="http://www.fastcgi.com/drupal/">FastCGI protocol</a>. It also
provides <a class="reference external" href="http://docs.python.org/distutils/">distutils</a> commands for building, distributing and installing
<a class="reference external" href="http://www.iis.net/downloads/microsoft/web-deploy">Microsoft Web Deploy</a> (MSDeploy) packages through the <a class="reference external" href="http://www.microsoft.com/web/downloads/platform.aspx">Web Platform
Installer</a> (WebPI).</p>
<p>The goals of the code in <a class="reference external" href="https://github.com/rpatterson/iiswsgi">iiswsgi</a> are to do the following for
deploying WSGI apps on IIS:</p>
<ul class="simple">
<li><p>make it open source as far as possible, right up to IIS</p></li>
<li><p>be Pythonic as far as possible, right up to the MSDeploy packaging</p></li>
<li><p>re-use our existing tool-chain for distributing packages</p></li>
<li><p>share the maintenance burden for a WSGI on Windows story across the community</p></li>
</ul>
<p>For the <a class="reference external" href="http://plone.org">Plone</a> project, it’s always been simultaneously a necessity
that we support a Windows deployment story and one of our biggest pain
points. The Windows installers have always been very different from
the other installers. They have had different layouts from our user
and developer documentation and even from each other. They have never
been maintained or supported by more than one entity, either a company
or an individual, and as such have often and ultimately languished.
And as for the poor individuals who have tackled the Windows
installers, they have almost always burned out and can no longer
provide any significant Windows support at all. This is not a healthy
open source community dynamic. And yet there is wide consensus that
it’s not an option <em>not</em> to have a Windows deployment story.</p>
<p>My hope is that by generalizing the IIS deployment architecture as a
<a class="reference external" href="https://github.com/rpatterson/iiswsgi#iiswsgi-fcgi-gateway">WSGI server</a> and <a class="reference external" href="https://github.com/rpatterson/iiswsgi#build-msdeploy-package">distutils commands</a>, it can be of use to the
general Python <a class="reference external" href="http://wsgi.readthedocs.org/en/latest/">WSGI</a> world. I also hope that by doing things ‘The
Right Way’, it will be something that will be clearer and easy to
support and maintain. With those two together maybe we can solve the
burnout issue by distributing the maintenance load. I’d very much
appreciate any help to that end, particularly including feedback on
how to get there. I don’t care where the code lives and would be
happy to see some of it merged back into the packages it derives from
or moved into larger packages. So please let me know if you’d like to
coordinate moving things around with me.</p>
<section id="help-needed">
<h2>Help Needed</h2>
<p>Any contributions are very welcome. Here are a few things I’m looking
for in particular:</p>
<ul class="simple">
<li><p>addressing <a class="reference external" href="https://github.com/rpatterson/iiswsgi#known-issues">Known Issues</a></p></li>
<li><p>IIS app name and Python dist name conventions</p></li>
<li><p>fostering community ownership</p></li>
<li><p>writing tests</p></li>
</ul>
<p>I’m particularly apologetic for the last one, I’m ashamed by the lack
of tests. In my defense, this whole problem was such a fog for me
when I started that I just needed to start writing things and poking
around. Believe me this is not my usual MO, I almost always do TDD
and beg your forgiveness. :-)</p>
<p>I look forward to getting this going!</p>
<div class="note update admonition">
<p class="admonition-title">Updated on 30 October 2012</p>
<p>Imported from Plone on Mar 15, 2021. The date for this update is the last
modified date in Plone.</p>
</div>
</section>
</section>
iiswsgi provides a WSGI server providing a FCGI gateway to IIS and setup.py commands for distributing apps as WebPI packages2012-10-30T00:00:00+00:00https://www.rpatterson.net/blog/announcing-plone-on-webpi/Plone lands on IIS!2012-10-30T00:00:00+00:00Ross Patterson<section id="plone-lands-on-iis">
<blockquote>
<div><p>Help me test a new GUI Plone install on Windows and IIS.</p>
</div></blockquote>
<p>Just in time for the scariest night of the year, my Windows installer
work based on the <a class="reference external" href="http://www.microsoft.com/web/downloads/platform.aspx">Web Platform Installer</a> (WebPI) is finally ready
to test. So <em>PLEASE</em> fire up your Windows VMs, try the <a class="reference internal" href="#quick-start">Quick Start</a>
below and report what your experience is. Then take a look at the
<a class="reference external" href="https://github.com/rpatterson/iiswsgi#known-issues">Known Issues</a> and help with any of them if you can. In particular,
any assistance getting the FCGI gateway to work under full IIS, not
just IIS Express would be <em>very</em> helpful. You may also want to try the <a class="reference external" href="https://github.com/rpatterson/iiswsgi#quick-start">Quick Start from iiswsgi</a> to install a <a class="reference external" href="docs.pylonsproject.org/projects/pyramid">Pyramid</a> project under IIS.</p>
<p>Wanting to do things the right way, most of my work has been on a
<a class="reference external" href="https://github.com/rpatterson/iiswsgi#iiswsgi-fcgi-gateway">generalized WSGI server</a> which acts as an FCGI gateway to IIS and a
<a class="reference external" href="https://github.com/rpatterson/iiswsgi#the-msdeploy-package">set of distutils commands</a> for building and distributing Web Deploy
packages. See my <a class="reference external" href="./python-web-apps-on-iis">previous post on WebPI</a> for more of the history
and the <a class="reference external" href="https://github.com/rpatterson/iiswsgi#iiswsgi">iiswsgi</a> <code class="docutils literal notranslate"><span class="pre">README.rst</span></code> for more details. In the meantime,
<em>please</em> test this stuff!</p>
<p>Between my last post and now, I’ve overcome most of the hurdles to a
sufficient degree that I think that the solutions, workarounds, or
hacks involved are good enough to use as our Windows story. In
particular, the hacks I have to use to <a class="reference external" href="https://github.com/rpatterson/iiswsgi#msdeploy-install-bootstrap">find the right
APPL_PHYSICAL_PATH</a> after install and the workaround I use to
<a class="reference external" href="https://github.com/rpatterson/iiswsgi#id26">register the IIS FCGI application</a> I think are robust enough to rely
upon even if it’s horrible that we have to use them.</p>
<p>Those of you who have offered help with this Windows stuff, I’m so
sorry about my delays in following up with y’all. There’s just been
an endless number of points between the state of things at the time
and where I had to get things in order to provide you specific things
to test and a way to test them. At any rate, the time is <em>now</em>, so
please all of you who contacted me or who I was put in touch with,
test it now and look at the <a class="reference external" href="https://github.com/rpatterson/iiswsgi#known-issues">Known Issues</a> for stuff you might be
able to help with. And if you have a MS suppport contract, please
submit support requests as I’ve described there.</p>
<p>I have one last note I hope isn’t in poor tastes. I have put way too
much of my own time into this thing, so recouping anything would be a
help. Here’s <a class="reference external" href="https://www.gittip.com/rpatterson/">my gittip</a> page, <a class="reference external" href="mailto:me%40rpatterson.net">my PayPal is my email</a> and I’m open
to any other suggestions as to how I might get some compensation for
this. All that said, it has been a labor of… well, not love for the
work, but certtainly love for the community. :-) You know what I mean
so it’s fine if nothing comes of it.</p>
<p>Onward!</p>
<section id="quick-start">
<h2>Quick Start</h2>
<p>The <a class="reference external" href="https://github.com/rpatterson/iiswsgi#iiswsgi">iiswsgi</a> distribution includes two sample IIS apps which can be
installed through WebPI once the custom feed has been added:</p>
<ol class="arabic simple">
<li><p>ATM, requires a machine with <code class="docutils literal notranslate"><span class="pre">svn.exe</span></code> and <code class="docutils literal notranslate"><span class="pre">git.exe</span></code> on the
<code class="docutils literal notranslate"><span class="pre">PATH</span></code> since it requires a couple of unreleased fixes.</p></li>
<li><p>Install and Launch <a class="reference external" href="http://www.microsoft.com/web/downloads/platform.aspx">Web Platform Installer</a></p></li>
<li><p>Use the search box in the upper-right to search for <cite>Web Matrix</cite></p></li>
<li><p>Click add next to the most recent <cite>Web Matrix</cite> entry, then
<cite>Install</cite> in the lower-right and follow the instructions</p></li>
<li><p>Open the <cite>Options</cite> dialog by clicking the link on the lower-right</p></li>
<li><p>Under <cite>Custom Feeds</cite>, add the <a class="reference external" href="http://dist.plone.org/release/4.2/PloneIISApp-4.2-py2.7-win32.webpi.xml">URL for latest *.webpi.xml file</a>
from the <a class="reference external" href="http://dist.plone.org/">Plone release</a> to install and click <cite>Add feed</cite></p></li>
<li><p>Under <cite>Which Web Server…?</cite>, check <cite>IIS Express</cite> and then click
<cite>OK</cite></p></li>
<li><p>Use the search box in the upper-right to search for <cite>Plone</cite></p></li>
<li><p>Click add next to <cite>Plone Application</cite> then <cite>Install</cite> in the
lower-right and follow the instructions</p></li>
</ol>
<div class="note update admonition">
<p class="admonition-title">Updated on 30 October 2012</p>
<p>Imported from Plone on Mar 15, 2021. The date for this update is the last
modified date in Plone.</p>
</div>
</section>
</section>
Help me test a new GUI Plone install on Windows and IIS.2012-10-29T00:00:00+00:00