Edgewall Software

Changes between Version 79 and Version 80 of TracStandalone


Ignore:
Timestamp:
Apr 10, 2010, 7:04:36 PM (14 years ago)
Author:
Christian Boos
Comment:

copied from 0.12/TracStandalone@6

Legend:

Unmodified
Added
Removed
Modified
  • TracStandalone

    v79 v80  
     1** Note: this page documents the 0.12 version of Trac, see [[0.11/TracStandalone]] if you need the previous version **
    12= Tracd =
    23
    3 Tracd is a lightweight standalone Trac web server. In most cases it's easier to setup and runs faster than the [wiki:TracCgi CGI script].
     4Tracd is a lightweight standalone Trac web server.
     5It can be used in a variety of situations, from a test or development server to a multiprocess setup behind another web server used as a load balancer.
    46
    57== Pros ==
    68
    79 * Fewer dependencies: You don't need to install apache or any other web-server.
    8  * Fast: Should be almost as fast as the [wiki:TracModPython mod_python] version (and much faster than the [wiki:TracCgi CGI]).
     10 * Fast: Should be almost as fast as the [wiki:TracModPython mod_python] version (and much faster than the [wiki:TracCgi CGI]), even more so since version 0.12 where the HTTP/1.1 version of the protocol is enabled by default
    911 * Automatic reloading: For development, Tracd can be used in ''auto_reload'' mode, which will automatically restart the server whenever you make a change to the code (in Trac itself or in a plugin).
    10   * Options for tracd: `-r, --auto-reload`
    1112
    1213== Cons ==
    1314
    14  * Fewer features: Tracd implements a very simple web-server and is not as configurable or as scalable as Apache HTTPD.
     15 * Fewer features: Tracd implements a very simple web-server and is not as configurable or as scalable as Apache httpd.
    1516 * No native HTTPS support: [http://www.rickk.com/sslwrap/ sslwrap] can be used instead,
    1617   or [http://trac.edgewall.org/wiki/STunnelTracd stunnel -- a tutorial on how to use stunnel with tracd] or Apache with mod_proxy.
     
    7273
    7374== Using Authentication ==
    74 `tracd` provides support for both Basic and Digest authentication. The default is to use Digest.
     75
     76Using tracd with Apache .htpasswd files:
     77
     78To create a .htpasswd file using htpasswd:
     79
     80{{{
     81 $ sudo htpasswd -c /path/to/env/.htpasswd username
     82}}}
     83then for additional users:
     84{{{
     85 $ sudo htpasswd /path/to/env/.htpasswd username2
     86}}}
     87then for starting the tracd (on windows skip the "=" after --basic-auth):
     88{{{
     89tracd -p 8080 --basic-auth=environmentname,/fullpath/environmentname/.htpasswd,/fullpath/environmentname /fullpath/environmentname
     90}}}
     91
     92 `environmentname` is the directory name of the Trac project folder, as opposed to `/fullpath/environmentname` which is the full path to the Trac project folder. See below for another example.
     93
     94Tracd provides support for both Basic and Digest authentication. The default is to use Digest; to use Basic authentication, replace `--auth` with `--basic-auth` in the examples below. (You must still specify a dialogic "realm", which can be an empty string by trailing the BASICAUTH with a comma.)
    7595
    7696  ''Support for Basic authentication was added in version 0.9.''
     
    190210}}}
    191211
    192 Note: If you would like to use --basic-auth you need to use htpasswd tool from apache server to generate .htpasswd file. The remaining part is similar but make sure to use empty realm (i.e. coma after path). When using on Windows make sure to use -m option for it (did not tested it on *nix, so not sure if that is the case there).  If you do not have Apache, [trac:source:/tags/trac-0.11b2/contrib/htpasswd.py htpasswd.py] may help.  (Note that it requires a `crypt` or `fcrypt` module; see the source comments for details.)
     212
     213Note: If you would like to use --basic-auth you need to use htpasswd tool from apache server to generate .htpasswd file. The remaining part is similar but make sure to use empty realm (i.e. coma after path). Make sure to use -m option for it.  If you do not have Apache, [trac:source:/tags/trac-0.11/contrib/htpasswd.py htpasswd.py] may help.  (Note that it requires a `crypt` or `fcrypt` module; see the source comments for details.)
    193214
    194215It is possible to use md5sum utility to generate digest-password file using such method:
     
    202223=== Serving static content ===
    203224
    204 If `tracd` is the only webserver used for the project,
     225If `tracd` is the only web server used for the project,
    205226it can also be used to distribute static content
    206227(tarballs, Doxygen documentation, etc.)
     
    211232Example: given a `$TRAC_ENV/htdocs/software-0.1.tar.gz` file,
    212233the corresponding relative URL would be `/<project_name>/chrome/site/software-0.1.tar.gz`,
    213 which in turn can be written using the relative link syntax
    214 in the Wiki: `[/<project_name>/chrome/site/software-0.1.tar.gz]`
    215 
    216 Since 0.10, Trac supports a new `htdocs:` TracLinks
    217 syntax for the above. With this, the example link above can be written simply
    218 `htdocs:software-0.1.tar.gz`.
     234which in turn can be written as `htdocs:software-0.1.tar.gz` (TracLinks syntax) or `[/<project_name>/chrome/site/software-0.1.tar.gz]` (relative link syntax).
     235
     236 ''Support for `htdocs:` TracLinks syntax was added in version 0.10''
    219237
    220238=== Using apache rewrite rules ===
     
    228246
    229247----
    230 See also: TracInstall, TracCgi, TracModPython, TracGuide, [trac:TracOnWindowsStandalone?version=13#RunningTracdasservice Running tracd.exe as a Windows service]
     248See also: TracInstall, TracCgi, TracModPython, TracGuide, [trac:TracOnWindowsStandalone?version=13#RunningTracdasservice Running tracd.exe as a Windows service], [trac:TracOnWindowsIisAjp], [trac:TracNginxRecipe]