summaryrefslogtreecommitdiff
path: root/doc/userdir.txt
blob: 10ba065919cf95c7f650c3c6c71fcd9d667b73a7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
=======
userdir
=======

-------------------
Module: mod_userdir
-------------------

:Author: Jan Kneschke
:Date: $Date: 2004/08/29 09:43:49 $
:Revision: $Revision: 1.1 $

:abstract:
  The userdir module ... 
  
.. meta::
  :keywords: lighttpd, userdir
  
.. contents:: Table of Contents

Description
===========

The userdir module provides a simple way to link user-based directories into the global namespace of the webserver.

Requests in the form ``/~user/page.html`` are rewritten to take the file ``page.html`` from the home directory of the user.
If ``userdir.path`` is set, the path will be appended to the home directory
building the classic mapping of: ::

  userdir.path = "public_html"

  URL: http://www.example.org/~jan/index.html 
  Path: /home/jan/public_html/

To control which users should be able to use this feature you can set a list of usernames to include or exclude.

In case your mapping is independent of /etc/passwd you can use
``userdir.basepath``: ::

  userdir.path = "htdocs"
  userdir.basepath = "/var/www/users/"

  URL: http://www.example.org/~jan/index.html
  Path: /var/www/users/jan/htdocs/index.html

Options
=======

userdir.path
  usually it should be set to "public_html" to take ~/public_html/ as the document root
    
  Default: empty (document root is the home directory)
  Example: ::

    userdir.path = "public_html"

userdir.exclude-user
  list of usernames which may not use this feature

  Default: empty (all users may use it)
  Example: ::

    userdir.exclude-user = ( "root", "postmaster" )


userdir.include-user
  if set, only users from this list may use the feature

  Default: empty (all users may use it)

userdir.basepath
  if set, don't check /etc/passwd for homedir