|
| 1 | + Roundup |
| 2 | + ======= |
| 3 | + |
| 4 | + |
| 5 | +1. License |
| 6 | +========== |
| 7 | +This software is released under the GNU GPL. The copyright is held by Bizar |
| 8 | +Software Pty Ltd (http://www.bizarsoftware.com.au). |
| 9 | + |
| 10 | +The stylesheet included with this package has been copied from the Zope |
| 11 | +management interface and presumably belongs to Digital Creations. |
| 12 | + |
| 13 | + |
| 14 | + |
| 15 | +2. Installation |
| 16 | +=============== |
| 17 | +These instructions work on redhat 6.2 and mandrake 8.0 - with the caveat |
| 18 | +that these systems don't come with python 2.0 or newer installed, so you'll |
| 19 | +have to upgrade python before this stuff will work. |
| 20 | + |
| 21 | +Note that most of the following is configurable in the config.py, it's just |
| 22 | +not documented. At a minimum, you'll want to change the email addresses and |
| 23 | +mail host specification in the config. |
| 24 | + |
| 25 | + |
| 26 | +2.0 Prerequisites |
| 27 | +----------------- |
| 28 | +Either: |
| 29 | + . Python 2.0 with pydoc installed. See http://www.lfw.org/ for pydoc. |
| 30 | +or |
| 31 | + . Python 2.1 |
| 32 | + |
| 33 | +Both need the bsddb module. |
| 34 | + |
| 35 | + |
| 36 | +2.1 Initial Setup |
| 37 | +----------------- |
| 38 | + 1. Make a directory in /home/httpd/html called 'roundup'. |
| 39 | + 2. Copy the tar file's contents there. |
| 40 | + 3. "python roundup.py init" to initialise the database (by default, it |
| 41 | + goes in a directory called 'db' in the current directory). Choose a |
| 42 | + sensible admin password. |
| 43 | + 4. "chmod -R a+rw db" |
| 44 | + |
| 45 | + |
| 46 | +2.2 Mail |
| 47 | +-------- |
| 48 | +Set up a mail alias called "issue_tracker" as: |
| 49 | + "|/usr/bin/python /home/httpd/html/roundup/roundup-mailgw.py" |
| 50 | + |
| 51 | +In some installations (e.g. RedHat 6.2 I think) you'll need to set up smrsh |
| 52 | +so sendmail will accept the pipe command. In that case, symlink |
| 53 | +/etc/smrsh/python to /usr/bin/python and change the command to: |
| 54 | + "|python /home/httpd/html/roundup/roundup-mailgw.py" |
| 55 | + |
| 56 | + |
| 57 | +2.3 Web Interface |
| 58 | +----------------- |
| 59 | +This software will work through apache or stand-alone. |
| 60 | + |
| 61 | +Stand-alone: |
| 62 | + 1. Edit server.py at the bottom to set your hostname and a port that is free. |
| 63 | + 2. "python server.py" |
| 64 | + 3. Load up the page "/" using the port number you set. |
| 65 | + |
| 66 | +Apache: |
| 67 | + 1. Make sure roundup.cgi is executable |
| 68 | + 2. Edit your /etc/httpd/conf/httpd.conf and make sure that the |
| 69 | + /home/httpd/html/roundup/roundup.cgi script will be treated as a CGI |
| 70 | + script. |
| 71 | + 3. Add the following to your /etc/httpd/conf/httpd.conf: |
| 72 | +snip >>> |
| 73 | +RewriteEngine on |
| 74 | +RewriteCond %{HTTP:Authorization} ^(.*) |
| 75 | +RewriteRule ^/roundup/roundup.cgi(.*) /home/httpd/html/roundup/roundup.cgi$1 [e=HTTP_CGI_AUTHORIZATION:%1,t=application/x-httpd-cgi,l] |
| 76 | +<<< snip |
| 77 | + note: the RewriteRule must be on one line - no breaks |
| 78 | + 4. Re-start your apache to re-load the config |
| 79 | + 5. Load up the page "/roundup/roundup.cgi/" |
| 80 | + |
| 81 | + |
| 82 | +3. Usage |
| 83 | +======== |
| 84 | +The system is designed to accessed through the command-line, e-mail or web |
| 85 | +interface. |
| 86 | + |
| 87 | +3.1 Command-line |
| 88 | +---------------- |
| 89 | +The command-line tool is called "roundup.py" and is used for most low-level |
| 90 | +database manipulations such as: |
| 91 | + . redefining the list of products ("create" and "retire" commands) |
| 92 | + . adding users manually, or setting their passwords ("create" and "set") |
| 93 | + . other stuff - run it with no arguments to get a better description of |
| 94 | + what it does. |
| 95 | + |
| 96 | + |
| 97 | +3.2 E-mail |
| 98 | +---------- |
| 99 | +See the docstring at the start of the roundup-mailgw.py source file. |
| 100 | + |
| 101 | + |
| 102 | +3.3 Web |
| 103 | +------- |
| 104 | +Hopefully, this interface is pretty self-explanatory... |
| 105 | + |
| 106 | +Index views may be modified by the following arguments: |
| 107 | + :sort - sort by prop name, optionally preceeded with '-' |
| 108 | + to give descending or nothing for ascending sorting. |
| 109 | + :group - group by prop name, optionally preceeded with '-' or |
| 110 | + to sort in descending or nothing for ascending order. |
| 111 | + :filter - selects which props should be displayed in the filter |
| 112 | + section. Default is all. |
| 113 | + :columns - selects the columns that should be displayed. |
| 114 | + Default is all. |
| 115 | + propname - selects the values the node properties given by propname |
| 116 | + must have (very basic search/filter). |
| 117 | + |
| 118 | + |
| 119 | + |
| 120 | +3. Design |
| 121 | +========= |
| 122 | +This software was written according to the specification found at |
| 123 | + http://software-carpentry.codesourcery.com/entries/second-round/track/Roundup/ |
| 124 | + |
| 125 | +... with some modifications. I've marked these in the source with 'XXX' |
| 126 | +comments when I remember to. |
| 127 | + |
| 128 | +In short: |
| 129 | + Class.find() - may match multiple properties, uses keyword args. |
| 130 | + |
| 131 | + Class.filter() - isn't in the spec and it's very useful to have at the Class |
| 132 | + level. |
| 133 | + |
| 134 | + CGI interface index view specifier layout part - lose the '+' from the |
| 135 | + sorting arguments (it's a reserved URL character ;). Just made no |
| 136 | + prefix mean ascending and '-' prefix descending. |
| 137 | + |
| 138 | + ItemClass - renamed to IssueClass to better match it only having one |
| 139 | + hypderdb class "issue". Allowing > 1 hyperdb class breaks the |
| 140 | + "superseder" multilink (since it can only link to one thing, and we'd |
| 141 | + want bugs to link to support and vice-versa). |
| 142 | + |
| 143 | + templates - the call="link()" is handled by special-case mechanisms in my |
| 144 | + top-level CGI handler. In a nutshell, the handler looks for a method on |
| 145 | + itself called 'index%s' or 'item%s' where %s is a class. Most items |
| 146 | + pass on to the templating mechanism, but the file class _always_ does |
| 147 | + downloading. It'll probably stay this way too... |
| 148 | + |
| 149 | + template - call="link(property)" may be used to link "the current node" |
| 150 | + (from an index) - the link text is the property specified. |
| 151 | + |
| 152 | + template - added functions that I found very useful: List, History and |
| 153 | + Submit. |
| 154 | + |
| 155 | + template - items must specify the message lists, history, etc. Having them |
| 156 | + by default was sometimes not wanted. |
| 157 | + |
| 158 | + template - index view determines its default columns from the template's |
| 159 | + <property> tags. |
| 160 | + |
| 161 | + template - menu() and field() look awfully similar now .... ;) |
| 162 | + |
| 163 | + roundup.py - the command-line tool has a lot more commands at its disposal |
| 164 | + |
| 165 | + |
| 166 | +4. TODO |
| 167 | +======= |
| 168 | +Most of the TODO items are captured in comments in the code. In summary: |
| 169 | + |
| 170 | +in general: |
| 171 | + . better error handling (nicer messages for users) |
| 172 | + . possibly revert the entire damn thing to 1.5.2 ... :( |
| 173 | +hyperdb: |
| 174 | + . transaction support |
| 175 | +roundupdb: |
| 176 | + . split the file storage into multiple files |
| 177 | +roundup-mailgw: |
| 178 | + . errors as attachments |
| 179 | + . snip signatures? |
| 180 | +server: |
| 181 | + . check the source file timestamps before reloading |
| 182 | +date: |
| 183 | + . blue Date.__sub__ needs food, badly |
| 184 | +config |
| 185 | + . default to blank config in distribution and warn appropriately |
| 186 | +roundup_cgi |
| 187 | + . searching |
| 188 | + . keep form fields in form on bad submission - only clear it if all ok |
| 189 | + |
| 190 | + |
| 191 | + |
| 192 | +5. Known Bugs |
| 193 | +============= |
| 194 | + |
| 195 | +http://dirk.adroit/roundup/roundup.cgi/issue?%3Acolumns%3Dactivity%2Cstatus%2Ctitle&%3Asort%3Dtitle%2C-activity&%3Agroup%3Dpriority |
| 196 | + |
| 197 | +date: |
| 198 | + . date subtraction doesn't work correctly "if the dates cross leap years, |
| 199 | + phases of the moon, ..." |
| 200 | + |
| 201 | +The software still probably has bugs. Please let me know when you find 'em. |
| 202 | +Patches are nice, but there'll probably be a good chance I've changed the |
| 203 | +code (there's not much to it ;) so a good description will be appreciated |
| 204 | +as well. |
| 205 | + |
| 206 | + |
| 207 | + |
| 208 | +6. Author |
| 209 | +========= |
| 210 | + |
| 211 | + |
| 212 | + |
| 213 | +7. Thanks |
| 214 | +========= |
| 215 | +Well, Ping, of course ;) |
| 216 | + |
| 217 | +Anthony Baxter, for some good first-release feedback. |
| 218 | + |
0 commit comments