Edgewall Software

TracOnWindows: Step_by_Step-installation-manual.txt

File Step_by_Step-installation-manual.txt, 4.1 KB (added by anders_emajl@…, 14 years ago)

A TracOnWindows step by step guide to fast get up and running. This version use windows 2003 std SP2 and Trac 0.11.2.1 with Python 2.5.4. together with the webserver tracd and authentication.

Line 
1Trac information can be found on http://trac.edgewall.org/wiki/TracOnWindows concerning Windows install
2
3On a clean standard Windows 2003 server with at least SP2
4
5Begin by downloading
6-Python 2.5.4.msi
7-Setuptools-0.6c7.win32-py2.X.exe
8-Genshi-0.5.1.win32-py2.5
9-subversion .4.2 (svn-1.4.2-setup.exe)
10-Trac-0.11.2.1.win32
11
12Install in the following order
131 -Python 2.5.4.msi
142 -SetupTools 0.6c7
153 -Genshi 0.5.1
16
174 -Add to windows path (korrect to appriate application paths)
18;c:\Python25;C:\Python25\Scripts
19
205 -ReBoot system
21
22Install
236 -Subversion 1.4.2
247 -Trac 0.11.2
25
268 -Create Projects (sample paths)
27
28-create c:\SVN (for Subversion)
29-Create C:\Projects\Trac (for Trac projects)
30
31Optional: if you're using Trac with Subversion you can create a new repository for your source code:
32
33>md c:\projects\svn
34
359 -then create the repository (remember full path for later use with Trac project creation)
36
37>svnadmin create c:\SVN\svn-test
38-this causes Subversion to create a subdirectory (c:\SVN\svn-test) containing the basics of a Subversion project
39- if svnadmin is not accessable, check path variable (reboot might solve problem)
40
41
4210 -Create Trac projects place (trac-admin /path/to/myproject initenv)
43
44>trac-admin c:\projects\Trac initenv -starts a wizard
45-when asked for the "Path to repository" input the folder of the repository you just created C:/SVN/svn-test
46be sure to include the full path, including the drive letter, !!!!!! and use forward slashes.!!!!!!
47
48--------------------------------------------------------
49Project Name [My Project]> svn-test + [Enter]
50
51Database connecting string [sqlite:db/trac.db]> [Enter]
52
53Repository type [svn]> [Enter]
54
55Path to repository [/path/to/repos]> c:/SVN/svn-test + [Enter]
56
57Template directory [C:\Python25\share\trac\templates]> [Enter]
58---------------------------------------------------------
59
6011 -For authentication create trace-digest.py file
61
62save the python code (between the -- lines) into c:\Python25\Scripts\trace-digest.py
63---------------------------------------------------------
64from optparse import OptionParser
65import md5
66
67# build the options
68usage = "usage: %prog [options]"
69parser = OptionParser(usage=usage)
70parser.add_option("-u", "--username",action="store", dest="username", type = "string",
71 help="the username for whom to generate a password")
72parser.add_option("-p", "--password",action="store", dest="password", type = "string",
73 help="the password to use")
74(options, args) = parser.parse_args()
75
76# check options
77if (options.username is None) or (options.password is None):
78 parser.error("You must supply both the username and password")
79
80# Generate the string to enter into the htdigest file
81realm = 'trac'
82kd = lambda x: md5.md5(':'.join(x)).hexdigest()
83print ':'.join((options.username, realm, kd([options.username, realm, options.password])))
84---------------------------------------------------------
85
8612- create userauth file if using httpd webserver and --auth parameter (OBS not for -basic--auth)
87
88>trac-digest.py -u "admin" -p adminpassword >> C:\projects\users.txt
89
90Set user admin to be the Trac administrator
91>trac-admin c:\projects\trac\svn-test permission add "admin" TRAC_ADMIN
92
93
9413 -Startup the webserver to listen to port 80, with authentication. "*" means all projects
95
96!!!! NOTE no space in line below between --auth -> ,trac !!!!
97
98>tracd-script.py -p 80 --auth="*",C:\projects\users.txt,trac c:\projects\trac\svn-test
99
100
10114 -test website
102surf to localhost
103
104--------
105
106For smtp mail configuration, edit the trac.ini according to above, located in C:\Projects\conf or C:\Projects\%Projectname%\conf
107-----------------------
108
109smtp_enabled = true
110#avilable smtp server, authentication username and password
111smtp_server = mail.maildomain.com
112smtp_user = username
113smtp_password = password
114
115#outgoing port
116smtp_port = 25
117
118#automaticly send event mail to... ; -separation in list !!! can a lot of mails!!!
119smtp_always_cc = firstname@maildomain.com; secondname@maildomain.com
120
121#Displayed name and reply address
122smtp_from_name = Trac Administrator
123smtp_from = sendername@maildomain.com
124
125-----------