Changeset - ac701b421053
[Not reviewed]
beta
0 1 0
Marcin Kuzminski - 15 years ago 2010-11-22 03:51:28
marcin@python-works.com
fixed docs, for python-ldap import
1 file changed with 5 insertions and 5 deletions:
0 comments (0 inline, 0 general)
docs/setup.rst
Show inline comments
 
@@ -63,81 +63,81 @@ for full index rebuild You can use
 
- For full text search You can either put crontab entry for
 

	
 
This command can be run even from crontab in order to do periodical 
 
index builds and keep Your index always up to date. An example entry might 
 
look like this
 

	
 
::
 
 
 
 /path/to/python/bin/paster --repo-location=<location for repos> /path/to/rhodecode/production.ini
 
  
 
When using incremental(default) mode whoosh will check last modification date 
 
of each file and add it to reindex if newer file is available. Also indexing 
 
daemon checks for removed files and removes them from index. 
 

	
 
Sometime You might want to rebuild index from scratch. You can do that using 
 
the `-f` flag passed to paster command or, in admin panel You can check 
 
`build from scratch` flag.
 

	
 

	
 
Setting up LDAP support
 
-----------------------
 

	
 

	
 
RhodeCode starting from version 1.1 supports ldap authentication. In order
 
to use ldap, You have to install ldap-python package. This package is available
 
to use ldap, You have to install python-ldap package. This package is available
 
via pypi, so You can install it by running
 

	
 
::
 

	
 
 easy_install ldap-python
 
 easy_install python-ldap
 
 
 
::
 

	
 
 pip install ldap-python
 
 pip install python-ldap
 

	
 

	
 
ldap-python requires some certain libs on Your system, so before installing it 
 
python-ldap requires some certain libs on Your system, so before installing it 
 
check that You have at least `openldap`, and `sasl` libraries.
 

	
 
ldap settings are located in admin->permissions section,
 

	
 
Here's a typical ldap setup::
 

	
 
 Enable ldap  = checked                 #controlls if ldap access is enabled
 
 Host         = host.domain.org         #acctuall ldap server to connect
 
 Port         = 389 or 689 for ldaps    #ldap server ports
 
 Enable LDAPS = unchecked               #enable disable ldaps
 
 Account      = <account>               #access for ldap server(if required)
 
 Password     = <password>              #password for ldap server(if required)
 
 Base DN      = CN=users,DC=host,DC=domain,DC=org
 
 
 

	
 
`Account` and `Password` are optional, and used for two-phase ldap 
 
authentication so those are credentials to access Your ldap, if it doesn't 
 
support anonymous search/user lookups.
 

	
 
If all data are entered correctly, and `ldap-python` is properly installed
 
If all data are entered correctly, and `python-ldap` is properly installed
 
Users should be granted to access RhodeCode wit theire ldap accounts. When 
 
logging at the first time an special ldap account is created inside RhodeCode, 
 
so You can control over permissions even on ldap users. If such user exists 
 
already in RhodeCode database ldap user with the same username would be not 
 
able to access RhodeCode.
 

	
 
If You have problems with ldap access and believe You entered correct 
 
information check out the RhodeCode logs,any error messages sent from 
 
ldap will be saved there.
 

	
 

	
 
Nginx virtual host example
 
--------------------------
 

	
 
Sample config for nginx using proxy::
 

	
 
 server {
 
    listen          80;
 
    server_name     hg.myserver.com;
 
    access_log      /var/log/nginx/rhodecode.access.log;
 
    error_log       /var/log/nginx/rhodecode.error.log;
 
    location / {
 
            root /var/www/rhodecode/rhodecode/public/;
 
            if (!-f $request_filename){
0 comments (0 inline, 0 general)