Edgewall Software

Changes between Version 211 and Version 212 of TracOnWindows


Ignore:
Timestamp:
Dec 14, 2007, 2:20:43 PM (16 years ago)
Author:
Christian Boos
Comment:

First try at merging content with TracOnWindows/Python2.5@25 - needs more cleanup

Legend:

Unmodified
Added
Removed
Modified
  • TracOnWindows

    v211 v212  
    11[[PageOutline(2-3)]]
    2 = Trac on Windows =
    3 
    4 == Install Python ==
    5 
    6 Trac is written in [http://python.org Python], so you will first need to install Python.
    7 
    8 The recommended version of Python at this time is 2.4.4.  Many of Trac's dependencies are not available on Windows for Python 2.5, so that version is not yet recommended (but see [wiki:TracOnWindows/Python2.5 a workaround]).
    9 
     2= Trac On Windows =
     3
     4The installation of Trac on Windows is now much simpler, due to the drop of ClearSilver as the primary template engine in favor of Genshi (Clearsilver is still optionally supported in case you need to use a plugin that requires it).
     5
     6If furthermore you don't need to interface with Subversion, then all you need besides are a few Python packages.
     7It doesn't hurt to have an `svn` client at hand for checking out the latest "trunk" version of some packages, like Trac itself or Genshi.
     8
     9== Installing Python on Windows ==
     10
     11After the installation, don't forget to add the path to the directory where you chose to install Python to your PATH environment variable.  This is important to be able to run the Python executable from any directory in the command line.
     12
     13=== Python 2.4 ===
    1014Download and run the Python MSI installer:
    1115[http://www.python.org/ftp/python/2.4.4/python-2.4.4.msi python-2.4.4.msi]
    1216
    13 Then add the path to the directory where you chose to install Python to your PATH environment variable.  This is important to be able to run the Python executable from any directory in the command line.
    14 
    15 == Method 1: Experimental All-In-One Installer ==
    16 
    17 ''Note: I don't believe that this method works at all. I believe that it was authored when the latest version of pysqlite was compatible with python 2.4.4. At this time the latest version of pysqlite does NOT seem to work with 2.4.4. So when using this approach you end up with a trac installation that fails. You have to back out of all of this and then try method 2 below, which worked for me.''
    18 
    19 This installation script only requires a Python 2.4 installation and will download and install the basic Trac dependencies and optionally the Subversion libraries. It does not always succeed - see the section Troubleshooting below - if you have problems, try Method 3.
    20 
    21   1. Download and double-click this script to install Trac: [attachment:trac-0.10.3-win32-install.py?format=raw trac-0.10.3-win32-install.py]
    22   1. Download and run the installer for the Subversion command line tools: [http://subversion.tigris.org/files/documents/15/38369/svn-1.4.4-setup.exe svn-1.4.4-setup.exe] (only if you actually need to interface Trac with Subversion of course; since Trac 0.10, Subversion is not a requirement anymore)
    23   1. Once that's done you can skip ahead to [#GettingStarted Getting Started].
    24 
    25 ,,If your network uses a web proxy server, you may have problems with the first step. You could try setting the HTTP_PROXY environment variable to refer to the proxy server. You can set this variable through Control Panel > System > Advanced > Environment Variables, or by using a command prompt from which you then run the script. In the latter example, you would "`SET HTTP_PROXY=http://your.proxy.server:port`" [enter] and then "`trac-0.10.3-win32-install.py`" [enter].,,
    26 
    27 
    28 == Method 2: Using Installers ==
     17
     18=== Python 2.5 ===
     19Simply [http://www.python.org/download/releases/2.5/#download-the-release download] and install the appropriate .msi for your Python platform:
     20 - [http://www.python.org/ftp/python/2.5/python-2.5.msi Python-2.5.msi]
     21 - [http://www.python.org/ftp/python/2.5/python-2.5.amd64.msi Python-2.5.amd64.msi]
     22 - [http://www.python.org/ftp/python/2.5/python-2.5.ia64.msi Python-2.5.ia64.msi]
     23
     24
     25== Method 1: Using Installers ==
    2926
    3027You need to download and install the following packages:
    3128|| Mandatory Packages ||  ||
    32 || '''[milestone:0.10.4 Trac 0.10.4]''' || [http://ftp.edgewall.com/pub/trac/trac-0.10.4.win32.exe trac-0.10.4.win32.exe] (works for Python 2.4 and 2.3) ||
    33 || '''ClearSilver''' || [http://www.clearsilver.net/downloads/win32/clearsilver-0.9.14.win32-py2.4.exe  clearsilver-0.9.14.win32-py2.4.exe] (or the [http://www.clearsilver.net/downloads/win32/clearsilver-0.9.14.win32-py2.3.exe Python 2.3 version]) ||
     29|| '''[milestone:0.11 Trac 0.11]''' || [[comment([http://ftp.edgewall.com/pub/trac/trac-0.11x.win32.exe trac-0.11x.win32.exe])]] ''not yet available'' (works for Python 2.4 and 2.3) ||
     30
    3431|| Optional Packages || (see notes below) ||
    3532|| ''[TracSubversion Subversion]'' || [http://subversion.tigris.org/files/documents/15/38214/svn-python-1.4.4.win32-py2.4.exe svn-python-1.4.4.win32-py2.4.exe] (or the [http://subversion.tigris.org/files/documents/15/38213/svn-python-1.4.4.win32-py2.3.exe Python 2.3 version]) ||
    3633|| ''PySqlite'' ||  [http://initd.org/pub/software/pysqlite/releases/2.3/2.3.4/pysqlite-2.3.4.win32-py2.4.exe pysqlite-2.3.4.win32-py2.4.exe] (or the [http://initd.org/pub/software/pysqlite/releases/2.3/2.3.4/pysqlite-2.3.4.win32-py2.3.exe Python 2.3 version]) ||
     34|| '''ClearSilver''' || [http://www.clearsilver.net/downloads/win32/clearsilver-0.9.14.win32-py2.4.exe  clearsilver-0.9.14.win32-py2.4.exe] (or the [http://www.clearsilver.net/downloads/win32/clearsilver-0.9.14.win32-py2.3.exe Python 2.3 version]) ||
    3735
    3836Notes:
     
    4341
    4442
    45 == Method 3: Manual Installation ==
    46 
    47 If you don't use the ''All-In-One Installer'', you'll have to download and install a few packages manually. This approach has a few more manual steps than the previous ones, but it is almost certain to work and you will know your installation much better at the end than with the more automated approaches. Total install time should be about 20 - 30 minutes if you have a speedy Internet connection.
     43== Method 2: Manual Installation ==
    4844
    4945=== Setuptools ===
     
    6561You should now be in the folder "C:\Python24\Scripts" where you can run the "easy_install" command to install the required software.
    6662
    67 === Install ClearSilver ===
    68 
    69 Install the [http://www.clearsilver.net/ ClearSilver] template language:
    70 {{{
    71 easy_install -f http://clearsilver.net/downloads clearsilver==0.9.14
    72 }}}
     63
     64
     65== Installing Genshi ==
     66
     67[http://genshi.edgewall.org/wiki/Download#Zippackage Download] the zip package:
     68 - [http://ftp.edgewall.com/pub/genshi/Genshi-0.4.4.zip Genshi-0.4.4.zip]
     69
     70Unzip to a folder and then from that folder run `python setup.py install` in a command window. (Make sure you have added the Python install path (e.g. C:\Program Files\Python25) to your system PATH variable. You can do this by right clicking on My Computer, clicking on Properties, selecting the Advanced tab, clicking the Environment Variables button, scrolling down the second list window until you see the 'Path' variable, then editing the string to add the Python install path. Then start command line for Genshi installation.)
     71
     72
     73== Installing Trac ==
     74
     75You simply need the latest trunk (0.11dev) (beta1 to come ''very'' soon) - to get this type the following in the command window. (Make sure you have added the Python install path (e.g. C:\Program Files\Python25) to your system PATH variable.  You can do this by right clicking on My Computer, clicking on Properties, selecting the Advanced tab, clicking the Environment Variables button, scrolling down the second list window until you see the 'Path' variable, then editing the string to add the Python install path).  Make sure you have [http://peak.telecommunity.com/DevCenter/EasyInstall#installation-instructions setuptools] installed before proceed.
     76
     77{{{
     78> cd C:\src
     79> svn checkout http://svn.edgewall.org/repos/trac/trunk
     80> cd trunk
     81> python setup.py install
     82}}}
     83
     84
     85Then, have a look at how to setup the TracEnvironment, use the TracStandalone web front-end and you're set.
     86
     87'''More specifically''', do this to get 0.11 with webadmin up and running:[[BR]]
     88
     89Create an administrator user (uses a script described elsewhere in the wiki)[[BR]]
     90python trac-digest.py -u adm -p adm >> c:\digest.txt[[BR]]
     91
     92Give that user all permissions[[BR]]
     93trac-admin c:\myproj permission add adm TRAC_ADMIN[[BR]]
     94
     95Now...[[BR]]
     96tracd -p 8000 --auth=myproj,c:\digest.txt,trac c:\myproj[[BR]]
     97
     98And you'll be able to see the Admin tab if you log in with 'adm'[[BR]]
     99
     100
     101== Installing mod_python for use with the Apache HTTP server ==
     102
     103If you are using an Apache server, you will need the latest mod_python for windows, built against Python v2.5.  Currently version 3.3.1 is available at the [http://httpd.apache.org/download.cgi Apache] website (click on "Other Files" and surf to `modpython/win/3.3.1/`).  However, you can also get other versions [http://nicolas.lehuen.com/download/mod_python/ here], courtesy of a very kind and wise gentleman called Nicolas Lehuen.
     104
     105== Installing plugins ==
     106
     107There's no need to install the WebAdmin plugin, as it has now been integrated in Trac proper.
     108Quite to the contrary, you should remove it if you're upgrading (it will be automatically disable though, so don't worry).
     109
     110See TracPlugins for details about plugin installation.
     111
     112For example, you can install the SpamFilter plugin. For that, you can grab them directly from the repository, and install it the same way you did for Trac:
     113{{{
     114> cd C:\src
     115> svn checkout http://svn.edgewall.org/repos/trac/sandbox/spam-filter
     116> cd spam-filter
     117> python setup.py install
     118}}}
     119Note if you catch an error:"ImportError: No module named setuptools" please download http://peak.telecommunity.com/dist/ez_setup.py and install the setuptools.
     120
     121If for some reason the above step fails, either because there's no package for the Windows platform you're using or the setuptools don't manage to read information from your svn working copy (if you used Subversion 1.4 for doing the checkout), you'll probably need to install first a recent `setuptools` package, itself available from `http://svn.python.org/projects/sandbox/trunk/setuptools`. Version 0.7a1 (!r51948) from the repository worked for me.
    73122
    74123=== Install PySQLite ===
     
    128177The installation process will begin with "Downloading http://subversion.tigris.org/downloads/svn-python-1.4.2.win32-py2.4.exe" and -- if successful -- ends with "Processing dependencies for svn-python==1.4.2".
    129178
     179
     180=== Install ClearSilver (optional) ===
     181
     182Install the [http://www.clearsilver.net/ ClearSilver] template language:
     183{{{
     184easy_install -f http://clearsilver.net/downloads clearsilver==0.9.14
     185}}}
     186
     187
    130188=== Install Trac ===
    131189
    132 Download and run the latest stable Trac Windows installer:
    133 [http://ftp.edgewall.com/pub/trac/trac-0.10.win32.exe trac-0.10.3.win32.exe]
     190Download and run the latest stable Trac Windows installer: ''not yet available, see TracDownload#Tracdevel''
     191[[comment([http://ftp.edgewall.com/pub/trac/trac-0.10.win32.exe trac-0.10.3.win32.exe])]]
    134192
    135193'''Note:''' do '''not''' run easy_install on the Trac installer.  This is not currently supported and Trac will not work correctly when installed this way.
     
    137195When you run the installer, it displays a window titled '''Setup Trac 0.10'''. On the first window of the installation dialog, click Next to get started. Confirm your Python directory and your intended installation directory. Click Next. Click Next again to start the installation. When the process is over, click Finish to complete the installation.
    138196
    139 == Method 4: All-In-One Step-by-Step Installation Guide ==
    140 
    141 This points to an [http://community.sgdotnet.org/blogs/blackinkbottles_ink/archive/2006/12/18/Using-Trac-to-improve-the-efficiency-of-product-development-and-project-management.aspx external guide] including setup of Subversion, Apache and other dependencies with detailed steps from scratch. It also contains some recommended installation paths and the corresponding brief but sufficent configurations in various configuration files covered (eg httpd.conf of Apache).
    142 
    143197----
     198
     199
     200----
     201See also: TracOnWindows/Advanced, ["0.10/TracOnWindows"], ["0.9/TracOnWindows"]
     202
     203
    144204
    145205== Getting Started ==