1
loggerhead: A web viewer for ``bzr`` branches
2
==============================================
4
Loggerhead is a web viewer for projects in bazaar. It can be used to navigate
5
a branch history, annotate files, view patches, perform searches, etc.
6
It is heavily based on ``bazaar-webserve``, which is itself based on ``hgweb``
12
Loggerhead depends on:
14
1) SimpleTAL for templating.
15
On Ubuntu, ``sudo apt-get install python-simpletal``
16
or download from http://www.owlfish.com/software/simpleTAL/download.html
18
2) simplejson for producing JSON data.
19
On Ubuntu, ``sudo apt-get install python-simplejson``
20
or use `easy_install simplejson`.
22
3) Paste for the server. (You need version 1.2 or newer of Paste.)
23
On Ubuntu, ``sudo apt-get install python-paste``
24
or use `easy_install Paste`
26
4) Paste Deploy (optional, needed when proxying through Apache)
27
On Ubuntu, ``sudo apt-get install python-pastedeploy``
28
or use `easy_install PasteDeploy`
30
5) flup (optional, needed to use FastCGI, SCGI or AJP)
31
On Ubuntu, ``sudo apt-get install python-flup``
32
or use `easy_install flup`
34
Then simply run the 'serve-branches' with the branch you want to
35
serve on the command line:
39
./serve-branches ~/path/to/branch
41
The script listens on port 8080 so head to http://localhost:8080/ in
42
your browser to see the branch. You can also pass a directory that
43
contains branches to the script, and it will serve a very simple
44
directory listing at other pages.
46
You may update the Bazaar branches being viewed at any time.
47
Loggerhead will notice and refresh, and Bazaar uses its own branch
48
locking to prevent corruption.
50
To run loggerhead as a linux daemon:
52
1) Copy loggerheadd to ``/etc/init.d``
54
2) Edit the file to configure where your loggerhead is installed, and which
55
serve-branches options you would like.
57
3) Register the service
60
a) on upstart based systems like Ubuntu run:
61
``update-rc.d loggerheadd defaults``
63
b) on Sysvinit based systems like Centos or SuSE run:
64
``chkconfig --add loggerheadd``
67
Loggerhead as a Bazaar Plugin
68
-----------------------------
70
This branch contains experimental support for using Loggerhead as a Bazaar
71
plugin. To use it, place the top-level Loggerhead directory (the one
72
containing this file) at ``~/.bazaar/plugins/loggerhead``.
78
To hide branches from being displayed, add to ``~/.bazaar/locations.conf``,
79
under the branch's section:
87
More configuration options to come soon.
90
Serving Loggerhead from Behind Apache
91
-------------------------------------
93
If you want to view Bazaar branches from your existing Apache
94
installation, you'll need to configure Apache to proxy certain
95
requests to Loggerhead. Adding lines like this to you Apache
96
configuration is one way to do this:
98
.. code-block:: apache
100
<Location "/branches/">
101
ProxyPass http://127.0.0.1:8080/branches/
102
ProxyPassReverse http://127.0.0.1:8080/branches/
105
If Paste Deploy is installed, the :command:`serve-branches` script can be
106
run behind a proxy at the root of a site, but if you're running it at
107
some path into the site, you'll need to specify is using
108
``--prefix=/some_path``.
114
Search is currently supported by using the bzr-search plugin (available
115
at: ``https://launchpad.net/bzr-search``
116
You need to have the plugin installed and each branch indexed to allow
117
searching on branches.
123
Loggerhead is loosely based on bazaar-webserve, which was loosely
124
based on hgweb. Discussion should take place on the bazaar-dev
125
mailing list at bazaar@lists.canonical.com. You can join the list at
126
<https://lists.ubuntu.com/mailman/listinfo/bazaar>. You don't need to
127
subscribe to post, but your first post will be held briefly for manual
130
Bugs are tracked on Launchpad; start at:
132
https://bugs.launchpad.net/loggerhead
138
To run loggerhead tests, you will need the package python-nose,
139
and run in the loggerhead directory:
153
https://launchpad.net/loggerhead