SPECS: trac.spec mod_python
Kamil Jakubowski
jakubowski.kamil at 3vnet.pl
Sat Jan 14 19:33:04 CET 2006
Witam,
- wersja podbita na 0.9.3
- patch trac-util.patch nie jest juz potrzebny
- zmiana trac-apache.conf
- rel 0.9
Zmienilem trac-apache.conf.
Teraz domyslnie Trac uzywa mod_python.
http://projects.edgewall.com/trac/wiki/TracModPython
mod_python jest w tym wypadku jakies 10x wydajniejszy.
Porownywalnie czas ladowania strony z 12s spadl do 1.2s
Perl w polaczeniu z Pythonem wyraznie sie zapycha przy wiekszym obciazeniu.
Prosze mnie poprawic jezeli cos jest zle
-------------- next part --------------
# $Id: trac-apache.conf,v 1.4 2005/12/06 12:41:36 glen Exp $
# Trac need to know where the database is located
# TracModPython
# http://projects.edgewall.com/trac/wiki/TracModPython
<IfModule mod_python.c>
<Location /trac>
SetHandler mod_python
PythonHandler trac.web.modpython_frontend
PythonOption TracEnvParentDir /var/lib/trac
PythonOption TracUriRoot /trac
</Location>
</IfModule>
# You might want to activate following urls
# to have easy access to trac as http://YOURSITE/trac/YOURPROJECT
#RedirectMatch ^/YOURPROJECT$ http://YOURSITE/trac/YOURPROJECT
#RedirectMatch ^/YOURPROJECT/$ http://YOURSITE/trac/YOURPROJECT
# You need this to allow users to authenticate
# trac.htpasswd can be created with
# cmd 'htpasswd -c trac.htpasswd'
# do 'man htpasswd' to see all the options
<Location /trac/login>
AuthType Basic
AuthName "trac"
AuthUserFile /etc/webapps/trac/htpasswd
Require valid-user
</location>
Alias /trac/ /usr/share/trac/htdocs/
<Directory /usr/share/trac/htdocs/>
Options Indexes MultiViews
AllowOverride None
Order allow,deny
Allow from all
</Directory>
# TracCgi
# http://projects.edgewall.com/trac/wiki/TracCgi
#<IfModule mod_env.c>
# <Location /trac/trac.cgi>
# SetEnv TRAC_ENV "/var/lib/trac/project"
# </Location>
#</IfModule>
# You might want to activate following urls
# to have easy access to trac as http://YOURSITE/trac
#RedirectMatch ^/trac$ http://YOURSITE/trac/trac.cgi
#RedirectMatch ^/trac/$ http://YOURSITE/trac/trac.cgi
#ScriptAlias /trac/trac.cgi /usr/share/trac/cgi-bin/trac.cgi
# You need this to allow users to authenticate
# trac.htpasswd can be created with
# cmd 'htpasswd -c trac.htpasswd'
# do 'man htpasswd' to see all the options
#<Location /trac/trac.cgi/login>
# AuthType Basic
# AuthName "trac"
# AuthUserFile /etc/trac/htpasswd
# Require valid-user
#</location>
#Alias /trac/ /usr/share/trac/htdocs/
#<Directory /usr/share/trac/htdocs/>
# Options Indexes MultiViews
# AllowOverride None
# Order allow,deny
# Allow from all
#</Directory>
-------------- next part --------------
--- trac-apache.conf 2006-01-12 02:58:26.000000000 +0100
+++ trac-apache.conf.new 2006-01-14 18:25:53.206238500 +0100
@@ -1,27 +1,31 @@
# $Id: trac-apache.conf,v 1.4 2005/12/06 12:41:36 glen Exp $
# Trac need to know where the database is located
-<IfModule mod_env.c>
- <Location /trac/trac.cgi>
- SetEnv TRAC_ENV "/var/lib/trac/project"
+
+# TracModPython
+# http://projects.edgewall.com/trac/wiki/TracModPython
+<IfModule mod_python.c>
+ <Location /trac>
+ SetHandler mod_python
+ PythonHandler trac.web.modpython_frontend
+ PythonOption TracEnvParentDir /var/lib/trac
+ PythonOption TracUriRoot /trac
</Location>
</IfModule>
# You might want to activate following urls
-# to have easy access to trac as http://YOURSITE/trac
-#RedirectMatch ^/trac$ http://YOURSITE/trac/trac.cgi
-#RedirectMatch ^/trac/$ http://YOURSITE/trac/trac.cgi
-
-ScriptAlias /trac/trac.cgi /usr/share/trac/cgi-bin/trac.cgi
+# to have easy access to trac as http://YOURSITE/trac/YOURPROJECT
+#RedirectMatch ^/YOURPROJECT$ http://YOURSITE/trac/YOURPROJECT
+#RedirectMatch ^/YOURPROJECT/$ http://YOURSITE/trac/YOURPROJECT
# You need this to allow users to authenticate
# trac.htpasswd can be created with
# cmd 'htpasswd -c trac.htpasswd'
# do 'man htpasswd' to see all the options
-<Location /trac/trac.cgi/login>
+<Location /trac/login>
AuthType Basic
AuthName "trac"
- AuthUserFile /etc/trac/htpasswd
+ AuthUserFile /etc/webapps/trac/htpasswd
Require valid-user
</location>
@@ -33,4 +37,37 @@
Allow from all
</Directory>
-# vim: filetype=apache ts=4 sw=4 et
+# TracCgi
+# http://projects.edgewall.com/trac/wiki/TracCgi
+#<IfModule mod_env.c>
+# <Location /trac/trac.cgi>
+# SetEnv TRAC_ENV "/var/lib/trac/project"
+# </Location>
+#</IfModule>
+
+# You might want to activate following urls
+# to have easy access to trac as http://YOURSITE/trac
+#RedirectMatch ^/trac$ http://YOURSITE/trac/trac.cgi
+#RedirectMatch ^/trac/$ http://YOURSITE/trac/trac.cgi
+
+#ScriptAlias /trac/trac.cgi /usr/share/trac/cgi-bin/trac.cgi
+
+# You need this to allow users to authenticate
+# trac.htpasswd can be created with
+# cmd 'htpasswd -c trac.htpasswd'
+# do 'man htpasswd' to see all the options
+#<Location /trac/trac.cgi/login>
+# AuthType Basic
+# AuthName "trac"
+# AuthUserFile /etc/trac/htpasswd
+# Require valid-user
+#</location>
+
+#Alias /trac/ /usr/share/trac/htdocs/
+#<Directory /usr/share/trac/htdocs/>
+# Options Indexes MultiViews
+# AllowOverride None
+# Order allow,deny
+# Allow from all
+#</Directory>
+
-------------- next part --------------
--- trac.spec 2005-12-20 16:58:18.000000000 +0100
+++ trac.spec.new 2006-01-14 19:07:43.000000000 +0100
@@ -4,15 +4,14 @@
Summary: Integrated scm, wiki, issue tracker and project environment
Summary(pl): Zintegrowane scm, wiki, system śledzenia problemów i środowisko projektowe
Name: trac
-Version: 0.9.2
-Release: 1
+Version: 0.9.3
+Release: 0.9
License: GPL
Group: Applications/WWW
Source0: http://ftp.edgewall.com/pub/trac/%{name}-%{version}.tar.gz
-# Source0-md5: 39e3af9e72a4aaa3b0217461638d9c03
+# Source0-md5: fce39070081f259020b4d60f044d9082
Source1: %{name}-apache.conf
Source2: %{name}.ico
-Patch0: %{name}-util.patch
URL: http://www.edgewall.com/trac/
BuildRequires: python >= 1:2.1
BuildRequires: python-devel >= 1:2.1
@@ -24,7 +23,7 @@
Requires: python-subversion >= 1.2.0
Requires: subversion >= 1.0.0
Requires: webapps
-# Requires: apache(mod_env)
+Requires: apache-mod_python >= 3.1.3
BuildArch: noarch
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
@@ -47,7 +46,6 @@
%prep
%setup -q
-#%patch0 -p1
%install
rm -rf $RPM_BUILD_ROOT
More information about the pld-devel-pl
mailing list