Edgewall Software

Changes between Version 15 and Version 16 of 0.12/TracInstall


Ignore:
Timestamp:
Mar 17, 2010, 9:50:28 AM (14 years ago)
Author:
mark.m.mcmahon@…
Comment:

Changed Prerequisites to "dependencies" as "optional prerequisites" sounded strange. Added references to TracWSGI, other small changes

Legend:

Unmodified
Added
Removed
Modified
  • 0.12/TracInstall

    v15 v16  
    1616
    1717
    18 == Prerequisites ==
    19 === Mandatory Prerequisites
     18== Dependencies ==
     19=== Mandatory Dependencies
    2020To install Trac, the following software packages must be installed:
    2121
     
    4040}}}
    4141 
    42 That way, the latest SQLite version will be downloaded and built into the
    43 bindings.
     42This will extract the SQLite code and build the bindings.
    4443
    4544SQLite 2.x is no longer supported. For SQLite 3.x, the pysqlite 1.1.x
     
    6665It is '''very''' important to read carefully the  [trac:MySqlDb MySqlDb] page before creating the database.
    6766
    68 === Optional Prerequisites
     67=== Optional Dependencies
    6968
    7069==== Version Control System ====
    7170
    7271===== Subversion =====
    73  * [http://subversion.apache.org/ Subversion], 1.5.x or 1.6.x and the '''''corresponding''''' Python bindings. Actually older versions starting from 1.0, like 1.2.4, 1.3.2 or 1.4.2, etc. should still work. For troubleshooting information, check the [trac:TracSubversion#Troubleshooting TracSubversion] page/
     72 * [http://subversion.apache.org/ Subversion], 1.5.x or 1.6.x and the '''''corresponding''''' Python bindings. Older versions starting from 1.0, like 1.2.4, 1.3.2 or 1.4.2, etc. should still work. For troubleshooting information, check the [trac:TracSubversion#Troubleshooting TracSubversion] page.
    7473
    7574There are [http://subversion.apache.org/packages.html pre-compiled SWIG bindings] available for various platforms. Note that Trac '''doesn't''' use [http://pysvn.tigris.org/ PySVN], neither does it work yet with the newer `ctype`-style bindings
     
    8483
    8584==== Web Server ====
    86  * A CGI-capable web server (see TracCgi), '''but usage of Trac as a cgi script
    87    is highly discouraged''', better use one of the following options,
    88  * a [http://www.fastcgi.com/ FastCGI]-capable web server (see TracFastCgi), or
    89  * an [http://tomcat.apache.org/connectors-doc/ajp/ajpv13a.html AJP]-capable web
    90    server (see [trac:TracOnWindowsIisAjp TracOnWindowsIisAjp]), or
     85A web server is optional because Trac is shipped with a server included, see the [#RunningtheStandaloneServer Running the Standalone Server ] section below.
     86
     87Alternatively you configure Trac to run in any of the following environments.
    9188 * [http://httpd.apache.org/ Apache] with
    9289   - [http://code.google.com/p/modwsgi/ mod_wsgi], see [wiki:TracModWSGI] and
    9390     http://code.google.com/p/modwsgi/wiki/IntegrationWithTrac
    9491   - [http://modpython.org/ mod_python 3.3.1], see TracModPython)
     92 * a [http://www.fastcgi.com/ FastCGI]-capable web server (see TracFastCgi)
     93 * an [http://tomcat.apache.org/connectors-doc/ajp/ajpv13a.html AJP]-capable web
     94   server (see [trac:TracOnWindowsIisAjp TracOnWindowsIisAjp])
     95 * A CGI-capable web server (see TracCgi), '''but usage of Trac as a cgi script
     96   is highly discouraged''', better use one of the following options,
    9597   
    9698
     
    162164easy_install --prefix=/usr/local --install-dir=/Library/Python/2.5/site-packages
    163165}}}
    164 Note: If installing on Mac OS X 10.6 running {{{ easy_install http://svn.edgewall.org/repos/trac/trunk }}} will install into /usr/local and /Library/Python/2.6/site-packages by default
     166Note: If installing on Mac OS X 10.6 running {{{ easy_install http://svn.edgewall.org/repos/trac/trunk }}} will install into {{{ /usr/local }}} and {{{ /Library/Python/2.6/site-packages }}} by default
    165167
    166168The above will place your `tracd` and `trac-admin` commands into `/usr/local/bin` and will install the Trac libraries and dependencies into `/Library/Python/2.5/site-packages`, which is Apple's preferred location for third-party Python application installations.
     
    178180[TracAdmin trac-admin] will prompt you for the information it needs to create the environment, such as the name of the project and the [TracEnvironment#DatabaseConnectionStrings database connection string]. If you're not sure what to specify for one of these options, just press `<Enter>` to use the default value.
    179181
    180 Leaving the database connection string empty in particular will always work as long as you have SQLite installed.
     182Using the default database connection string in particular will always work as long as you have SQLite installed.
    181183For the other [DatabaseBackend database backends] you should plan ahead and already have a database ready to use at this point.
    182184
     
    197199}}}
    198200
    199 Then, fire up a browser and visit `http://localhost:8000/`. You should get a simple listing of all environments that tracd knows about. Follow the link to the environment you just created, and you should see Trac in action. If you only plan on managing a single project with trac you can have the standalone server skip the environment list by starting it like this:
     201Then, fire up a browser and visit `http://localhost:8000/`. You should get a simple listing of all environments that `tracd` knows about. Follow the link to the environment you just created, and you should see Trac in action. If you only plan on managing a single project with Trac you can have the standalone server skip the environment list by starting it like this:
    200202{{{
    201203$ tracd -s --port 8000 /path/to/myproject
     
    204206== Running Trac on a Web Server ==
    205207
    206 Trac provides three options for connecting to a "real" web server: [wiki:TracCgi CGI], [wiki:TracFastCgi FastCGI] and [wiki:TracModPython mod_python]. For decent performance, it is recommended that you use either FastCGI or mod_python.
    207 
     208Trac provides various options for connecting to a "real" web server: [wiki:TracCgi CGI], [wiki:TracFastCgi FastCGI],[wiki:TracModWSGI mod_wsgi] and [wiki:TracModPython mod_python]. For decent performance, it is recommended that you use either FastCGI or mod_wsgi.
    208209
    209210Trac also supports [trac:TracOnWindowsIisAjp AJP] which may be your choice if you want to connect to IIS.
    210211
    211212==== Generating the Trac cgi-bin directory ====
     213{{{#!div style="background:#efe"
     214MMM: If I understand correctly mod_wsgi is preferred over mod_python. Does the section below apply to mod_wsgi also?
     215}}}
    212216
    213217In order for Trac to function properly with FastCGI or mod_python, you need to have a trac.cgi file. This is an executable which loads the appropriate Python code. It can be generated using the `deploy` option of [wiki:TracAdmin trac-admin].
     
    223227==== Setting up the Plugin Cache ====
    224228
    225 Some Python plugins need to be extracted to a cache directory. By default the cache resides in the home directory of the current user. When running Trac on a Web Server as a dedicated user (which is highly recommended) who has no home directory, this might prevent the plugins from starting. To override the cache location you can set the PYTHON_EGG_CACHE environment variable. Refer to your server documentation for detailed instructions.
     229Some Python plugins need to be extracted to a cache directory. By default the cache resides in the home directory of the current user. When running Trac on a Web Server as a dedicated user (which is highly recommended) who has no home directory, this might prevent the plugins from starting. To override the cache location you can set the PYTHON_EGG_CACHE environment variable. Refer to your server documentation for detailed instructions on how to set environment variables.
    226230
    227231== Configuring Authentication ==
     
    231235 * TracStandalone if you use the standalone server, `tracd`.
    232236 * TracCgi if you use the CGI or FastCGI methods.
     237 * TracModWSGI if you use the mod_python method.
    233238 * TracModPython if you use the mod_python method.
    234239
     
    236241== Automatic reference to the SVN changesets in Trac tickets ==
    237242
    238 You can configure SVN to automatically add a reference to the changeset into the ticket comments, whenever files are committed to the repository. The description of the commit needs to contain one of the following formulas:
    239  * '''Refs #123''' - to reference this changeset in #123 ticket
    240  * '''Fixes #123''' - to reference this changeset and close #123 ticket with the default status ''fixed''
     243You can configure SVN to automatically add a reference to the changeset into the ticket comments, whenever changes are committed to the repository. The description of the commit needs to contain one of the following formulas:
     244 * '''`Refs #123`''' - to reference this changeset in `#123` ticket
     245 * '''`Fixes #123`''' - to reference this changeset and close `#123` ticket with the default status ''fixed''
    241246
    242247This functionality requires a post-commit hook to be installed as described in [wiki:TracRepositoryAdmin#ExplicitSync TracRepositoryAdmin], and enabling the optional commit updater components by adding the following line to the `[components]` section of your [wiki:TracIni#components-section trac.ini], or enabling the components in the "Plugins" admin panel.
     
    248253== Using Trac ==
    249254
    250 Once you have your Trac site up and running, you should be able to browse your subversion repository, create tickets, view the timeline, etc.
     255Once you have your Trac site up and running, you should be able to create tickets, view the timeline, browse your version control repository if configured, etc.
    251256
    252257Keep in mind that anonymous (not logged in) users can by default access most but not all of the features. You will need to configure authentication and grant additional [wiki:TracPermissions permissions] to authenticated users to see the full set of features.