Changeset - 291f04a72288
[Not reviewed]
default
0 1 0
Mads Kiilerich (mads) - 6 years ago 2020-08-13 15:30:09
mads@kiilerich.com
Grafted from: b4fcc26d7ed5
docs: drop changing cwd in WSGI wrapper script

It was introduced in 5a31d387f347 and has never been in the virtualenv version
of the WSGI script, which "proves" it really is unnecessary.
1 file changed with 0 insertions and 5 deletions:
0 comments (0 inline, 0 general)
docs/setup.rst
Show inline comments
 
@@ -599,29 +599,24 @@ that, you'll need to:
 
- Add global Apache configuration to tell mod_wsgi that Python only will be
 
  used in the WSGI processes and shouldn't be initialized in the Apache
 
  processes::
 

	
 
    WSGIRestrictEmbedded On
 

	
 
- Create a WSGI dispatch script, like the one below. Make sure you
 
  check that the paths correctly point to where you installed Kallithea
 
  and its Python Virtual Environment.
 

	
 
  .. code-block:: python
 

	
 
      import os
 

	
 
      # sometimes it's needed to set the current dir
 
      os.chdir('/srv/kallithea/')
 

	
 
      import site
 
      site.addsitedir("/srv/kallithea/venv/lib/python3.7/site-packages")
 

	
 
      ini = '/srv/kallithea/my.ini'
 
      from logging.config import fileConfig
 
      fileConfig(ini, {'__file__': ini, 'here': '/srv/kallithea'})
 
      from paste.deploy import loadapp
 
      application = loadapp('config:' + ini)
 

	
 
  Or using proper virtualenv activation:
 

	
 
  .. code-block:: python
0 comments (0 inline, 0 general)