diff options
| author | Chris McDonough <chrism@plope.com> | 2011-09-02 00:23:23 -0400 |
|---|---|---|
| committer | Chris McDonough <chrism@plope.com> | 2011-09-02 00:23:23 -0400 |
| commit | 7c1549608daf2e3a6965320b1ef8362d8b4dd618 (patch) | |
| tree | 43ca8627665fe503c87937f1a1552df8bdb93bb3 /docs | |
| parent | 09387f5cb04eb08b18c24a41248af0a13648286e (diff) | |
| download | pyramid-7c1549608daf2e3a6965320b1ef8362d8b4dd618.tar.gz pyramid-7c1549608daf2e3a6965320b1ef8362d8b4dd618.tar.bz2 pyramid-7c1549608daf2e3a6965320b1ef8362d8b4dd618.zip | |
remove; too complex to document here
Diffstat (limited to 'docs')
| -rw-r--r-- | docs/narr/vhosting.rst | 49 |
1 files changed, 0 insertions, 49 deletions
diff --git a/docs/narr/vhosting.rst b/docs/narr/vhosting.rst index 086af78f7..8697df6a0 100644 --- a/docs/narr/vhosting.rst +++ b/docs/narr/vhosting.rst @@ -139,55 +139,6 @@ the same can be achieved using ``SetEnv``: Setting a virtual root has no effect when using an application based on :term:`URL dispatch`. -Fixing HTTP vs. HTTPS When Deploying Behind a Proxy ---------------------------------------------------- - -In a configuration where you have a :app:`Pyramid` server behind an Apache or -Nginx or Squid proxy which serves your website over SSL (as ``https``) as in -the above example in :ref:`virtual_root_support`, the request will be passed -by the proxy to an `http://`` URL that will be served by :app:`Pyramid`. -Because this is true, URLs generated by :app:`Pyramid` will be generated with -``http://`` instead of ``https://``; the SSL info has been "lost" during the -proxying. - -To work around this, convert your application to use a "pipeline" instead of -a simple "app" in your PasteDeploy configuration, then add ``prefix`` -middleware to the pipeline. For example, if your ``production.ini`` file has -a ``main`` section that looks like this: - -.. code-block:: ini - - [app:main] - use = egg:MyProject - -Convert it to look like this: - -.. code-block:: ini - - [app:myapp] - use = egg:MyProject - - [pipeline:main] - pipeline = - myapp - -Then add the ``paste.prefix`` middleware with no options to the pipeline: - -.. code-block:: ini - - [app:myapp] - use = egg:MyProject - - [filter:paste_prefix] - use = egg:PasteDeploy#prefix - - [pipeline:main] - pipeline = - paste_prefix - myapp - -This will have the side effect of retaining ``https`` URLs during generation. - Further Documentation and Examples ---------------------------------- |
