title: Multiple mod_wsgi apps on one virtual host directing to wrong app
body: <p>I'm trying to get two (or more) Django applications set up at subdirectories under the same domain, e.g.:</p>
  
  <pre><code>http://example.com/site1/
  http://example.com/site2/
  </code></pre>
  
  <p>I know that normally this works fine by setting up an apache virtualhost like this:</p>
  
  <pre><code>&lt;VirtualHost *:80&gt;
      ...
      WSGIScriptAlias /site1 /path/to/site1.wsgi
      WSGIScriptAlias /site2 /path/to/site2.wsgi
  &lt;/VirtualHost&gt;
  </code></pre>
  
  <p>Now, I've verified that each site works individually. But when I try to run both side-by-side, apache sends me to whichever site the worker process loaded first. Example:</p>
  
  <ol>
  <li>Restart apache configured to serve 6 threads</li>
  <li>Load example.com/site1/, get the correct page</li>
  <li>Load example.com/site2/, get the correct page</li>
  <li>Repeat 2 and 3 2 more times.</li>
  <li>Refresh example.com/site1/ repeatedly, watch it cycle from site to site.</li>
  </ol>
  
  <p>Effectively, for any given number of worker processes, it cycles through the total number of them sending the request to whichever one it hit first regardless of the WSGIScriptAlias directive. No matter what I do (setting WSGIProcessGroup, daemon mode vs. embedded mode,  or  directives) it continues to exhibit this behavior.</p>
  
  <p>If anyone can point out what I'm doing wrong here, that would be phenomenal!</p>