Skip to content

Commit e746821

Browse files
author
Richard Jones
committed
More tweaks to the licensing to make the Debian folks happy :)
Added an "instant gratification" mode - "python setup.py demo" installs a simple instance and runs the web server on it. Nosy is disabled.
1 parent 9d57cd7 commit e746821

File tree

7 files changed

+222
-30
lines changed

7 files changed

+222
-30
lines changed

CHANGES.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ Removed:
88
distribution.
99

1010
Feature:
11+
- new instant-gratification Demo Mode in setup
1112
- support setting of properties on message and file through web and
1213
email interface (thanks John Rouillard)
1314
- allow additional control over the roundupdb email sending (explicit

COPYING.txt

Lines changed: 65 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
Roundup Licensing
22
-----------------
33

4+
Copyright (c) 2003 Richard Jones ([email protected])
45
Copyright (c) 2002 eKit.com Inc (http://www.ekit.com/)
6+
Copyright (c) 2001 Bizar Software Pty Ltd (http://www.bizarsoftware.com.au/)
57

68
Permission is hereby granted, free of charge, to any person obtaining a copy
79
of this software and associated documentation files (the "Software"), to deal
@@ -22,24 +24,6 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
2224
SOFTWARE.
2325

2426

25-
Copyright (c) 2001 Bizar Software Pty Ltd (http://www.bizarsoftware.com.au/)
26-
27-
This module is free software, and you may redistribute it and/or modify
28-
under the same terms as Python 2.1 (the PSF LICENSE AGREEMENT), so long
29-
as this copyright message and disclaimer are retained in their original form.
30-
31-
IN NO EVENT SHALL BIZAR SOFTWARE PTY LTD BE LIABLE TO ANY PARTY FOR
32-
DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING
33-
OUT OF THE USE OF THIS CODE, EVEN IF BIZAR SOFTWARE PTY LTD HAS BEEN
34-
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
35-
36-
BIZAR SOFTWARE PTY LTD SPECIFICALLY DISCLAIMS ANY WARRANTIES, INCLUDING,
37-
BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
38-
FOR A PARTICULAR PURPOSE. THE CODE PROVIDED HEREUNDER IS ON AN "AS IS"
39-
BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE,
40-
SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
41-
42-
4327
PageTemplates Licensing
4428
-----------------------
4529

@@ -56,5 +40,67 @@ the following manner:
5640
HISTORY.txt.
5741
- editing to remove dependencies on Zope modules (see files for change notes)
5842

59-
The license for this code is in doc/ZPL.txt.
43+
The license for this code is the `Zope Public License (ZPL) Version 2.0`_,
44+
included below.
45+
46+
47+
Zope Public License (ZPL) Version 2.0
48+
-------------------------------------
49+
50+
This software is Copyright (c) Zope Corporation (tm) and
51+
Contributors. All rights reserved.
52+
53+
This license has been certified as open source. It has also
54+
been designated as GPL compatible by the Free Software
55+
Foundation (FSF).
56+
57+
Redistribution and use in source and binary forms, with or
58+
without modification, are permitted provided that the
59+
following conditions are met:
60+
61+
1. Redistributions in source code must retain the above
62+
copyright notice, this list of conditions, and the following
63+
disclaimer.
64+
65+
2. Redistributions in binary form must reproduce the above
66+
copyright notice, this list of conditions, and the following
67+
disclaimer in the documentation and/or other materials
68+
provided with the distribution.
69+
70+
3. The name Zope Corporation (tm) must not be used to
71+
endorse or promote products derived from this software
72+
without prior written permission from Zope Corporation.
73+
74+
4. The right to distribute this software or to use it for
75+
any purpose does not give you the right to use Servicemarks
76+
(sm) or Trademarks (tm) of Zope Corporation. Use of them is
77+
covered in a separate agreement (see
78+
http://www.zope.com/Marks).
79+
80+
5. If any files are modified, you must cause the modified
81+
files to carry prominent notices stating that you changed
82+
the files and the date of any change.
83+
84+
Disclaimer
85+
86+
THIS SOFTWARE IS PROVIDED BY ZOPE CORPORATION ``AS IS''
87+
AND ANY EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT
88+
NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
89+
AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN
90+
NO EVENT SHALL ZOPE CORPORATION OR ITS CONTRIBUTORS BE
91+
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
92+
EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
93+
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
94+
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
95+
HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
96+
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
97+
OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
98+
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
99+
DAMAGE.
100+
101+
102+
This software consists of contributions made by Zope
103+
Corporation and many individuals on behalf of Zope
104+
Corporation. Specific attributions are listed in the
105+
accompanying credits file.
60106

README.txt

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,28 @@
1+
=======================================================
2+
Roundup: an Issue-Tracking System for Knowledge Workers
3+
=======================================================
4+
5+
Copyright (c) 2003 Richard Jones ([email protected])
6+
Copyright (c) 2002 eKit.com Inc (http://www.ekit.com/)
7+
Copyright (c) 2001 Bizar Software Pty Ltd (http://www.bizarsoftware.com.au/)
8+
19

210
Installation
311
============
412
For installation instructions, please see installation.txt in the "doc"
513
directory.
614

15+
716
Upgrading
817
=========
918
For upgrading instructions, please see upgrading.txt in the "doc" directory.
1019

20+
1121
Usage and Other Information
1222
===========================
1323
See the index.txt file in the "doc" directory.
1424

1525

1626
License
1727
=======
18-
1928
See COPYING.txt
20-

doc/glossary.txt

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
Roundup Glossary
33
================
44

5-
:Version: $Revision: 1.4 $
5+
:Version: $Revision: 1.5 $
66

77
.. contents::
88

@@ -18,11 +18,15 @@ itemid
1818
item
1919
a collection of data that forms one entry in the hyperdb.
2020
property
21-
one element of data that makes up an item
21+
one element of data that makes up an item. In Roundup, item
22+
properties may be changed as needed - even after the tracker
23+
has been initialised and used in production.
2224
schema
2325
the definition of all the classes that make up an tracker
2426
tracker
2527
the schema and hyperdb that forms one issue tracker
28+
tracker home
29+
the physical location on disk of a tracker
2630

2731

2832
-----------------

doc/index.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@ Contents
66
========
77

88
- Overview_ and Features_ (pdf__)
9-
- Installation_ (pdf__) and Upgrading_ (pdf__)
9+
- Installation_ (pdf__) and Upgrading_ existing installs (pdf__)
1010
- `User Guide`_ (pdf__)
11-
- `Customising Roundup`_ (pdf__)
11+
- Configuring and `Customising Roundup`_ (pdf__)
1212
- `Maintaining Roundup Trackers`_ (pdf__)
1313
- `Roundup's Design`_ (pdf__) (original_)
1414
- `Developing Roundup`_ (pdf__)

doc/installation.txt

Lines changed: 60 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
Installing Roundup
33
==================
44

5-
:Version: $Revision: 1.44 $
5+
:Version: $Revision: 1.45 $
66

77
.. contents::
88

@@ -63,6 +63,20 @@ If the above fails, you may be using the wrong version of python. Try
6363
Roundup -- from installation and scripts.
6464

6565

66+
For The Really Impatient
67+
========================
68+
69+
If you just want to give Roundup a whirl Right Now, then simply run
70+
``python setup.py demo``. This will set up a simple demo tracker on your
71+
machine. When it's done, it'll print out a URL to point your web browser
72+
at so you may start playing. Three users will be set up:
73+
74+
1. anonymous - the "default" user with permission to do very little
75+
2. demo (password "demo") - a normal user who may create issues
76+
3. admin (password "admin") - an administrative user who has complete
77+
access to the tracker
78+
79+
6680
Installation
6781
============
6882

@@ -103,7 +117,8 @@ Basic Installation Steps
103117
and modify the python path accordingly.
104118

105119
2. To create a Roundup tracker (necessary to do before you can
106-
use the software in any real fashion):
120+
use the software in any real fashion), you need to set up a "tracker
121+
home":
107122

108123
a. (Optional) If you intend to keep your roundup trackers
109124
under one top level directory which does not exist yet,
@@ -243,7 +258,8 @@ There are three web interfaces to choose from:
243258
3. `Zope product - ZRoundup`_
244259

245260
You may need to give the web server user permission to access the tracker home
246-
- see the `shared environment steps`_ for information.
261+
- see the `shared environment steps`_ for information. You may also need to
262+
configure your system in some way - see `platform-specific notes`_.
247263

248264

249265
Web Server cgi-bin
@@ -314,6 +330,8 @@ Configure an Email Interface
314330
If you don't want to use the email component of Roundup, then remove the
315331
"``nosyreaction.py``" module from your tracker "``detectors``" directory.
316332

333+
See `platform-specific notes`_ for steps that may be needed on your system.
334+
317335
There are three supported ways to get emailed issues into the
318336
Roundup tracker. You should pick ONE of the following, all
319337
of which will continue my example setup from above:
@@ -419,9 +437,48 @@ templates, if you would like to hack on Roundup, or if you would
419437
like implementation details, you should read `Customising Roundup`_.
420438

421439

440+
Running Multiple Trackers
441+
=========================
442+
443+
Things to think about before you jump off the deep end and install
444+
multiple trackers, which involve additional URLs, user databases, email
445+
addresses, databases to back up, etc.
446+
447+
1. Do you want a tracker per product you sell/support? You can just add
448+
a new property to your issues called Product, and filter by that.
449+
2. Do you want to track internal software development issues and customer
450+
support issues separately? You can just set up an additiona "issue"
451+
class called "cust_issues" in the same tracker, mimicing the normal
452+
"issue" class, but with different properties.
453+
454+
422455
Platform-Specific Notes
423456
=======================
424457

458+
Windows
459+
-------
460+
461+
To have the Roundup web server start up when your machine boots up, set the
462+
following up in Scheduled Tasks (note, the following is for a cygwin setup):
463+
464+
Run
465+
``c:\cygwin\bin\bash.exe -c "roundup-server TheProject=/opt/roundup/trackers/support"``
466+
Start In
467+
``C:\cygwin\opt\roundup\bin``
468+
Schedule
469+
At System Startup
470+
471+
To have the Roundup mail gateway run periodically to poll a POP email address,
472+
set the following up in Scheduled Tasks:
473+
Run
474+
``c:\cygwin\bin\bash.exe -c "roundup-mailgw /opt/roundup/trackers/support pop roundup:roundup@mail-server"``
475+
Start In
476+
``C:\cygwin\opt\roundup\bin``
477+
Schedule
478+
Every 10 minutes from 5:00AM for 24 hours every day
479+
Stop the task if it runs for 8 minutes
480+
481+
425482
Sendmail smrsh
426483
--------------
427484

setup.py

Lines changed: 78 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
# BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE,
1717
# SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
1818
#
19-
# $Id: setup.py,v 1.44 2003-02-20 22:58:50 richard Exp $
19+
# $Id: setup.py,v 1.45 2003-04-07 03:47:44 richard Exp $
2020

2121
from distutils.core import setup, Extension
2222
from distutils.util import get_platform
@@ -137,7 +137,7 @@ def buildTemplates():
137137
tdir = os.path.join('roundup', 'templates', template)
138138
makeHtmlBase(tdir)
139139

140-
if __name__ == '__main__':
140+
def main():
141141
# build list of scripts from their implementation modules
142142
roundup_scripts = map(scriptname, glob('roundup/scripts/[!_]*.py'))
143143

@@ -218,4 +218,80 @@ def buildTemplates():
218218
data_files = installdatafiles
219219
)
220220

221+
def install_demo():
222+
''' Install a demo server for users to play with for instant gratification.
223+
224+
Sets up the web service on localhost port 8080. Disables nosy lists.
225+
'''
226+
import shutil, socket, errno, BaseHTTPServer
227+
228+
# create the instance
229+
home = os.path.abspath('demo')
230+
try:
231+
shutil.rmtree(home)
232+
except os.error, error:
233+
if error.errno != errno.ENOENT:
234+
raise
235+
from roundup import init, instance, password
236+
init.install(home, 'classic')
237+
# don't have email flying around
238+
os.remove(os.path.join(home, 'detectors', 'nosyreaction.py'))
239+
init.write_select_db(home, 'anydbm')
240+
241+
# figure basic params for server
242+
hostname = socket.gethostname()
243+
port = 8080
244+
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
245+
s.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1)
246+
while 1:
247+
print 'Trying to set up web server on port %d ...'%port,
248+
try:
249+
s.bind((hostname, port))
250+
except socket.error, error:
251+
if error.errno != errno.EADDRINUSE:
252+
raise
253+
print 'already in use.'
254+
port += 100
255+
else:
256+
print 'should be ok.'
257+
break
258+
url = 'http://%s:%s/demo/'%(hostname, port)
259+
260+
# write the config
261+
f = open(os.path.join(home, 'config.py'), 'r')
262+
s = f.read().replace('http://tracker.example/cgi-bin/roundup.cgi/bugs/',
263+
url)
264+
f.close()
265+
f = open(os.path.join(home, 'config.py'), 'w')
266+
f.write(s)
267+
f.close()
268+
269+
# initialise the database
270+
init.initialise(home, 'admin')
271+
272+
# add the "demo" user
273+
tracker = instance.open(home)
274+
db = tracker.open('admin')
275+
db.user.create(username='demo', password=password.Password('demo'),
276+
realname='Demo User', roles='User')
277+
db.commit()
278+
db.close()
279+
280+
# ok, so start up the server
281+
from roundup.scripts.roundup_server import RoundupRequestHandler
282+
RoundupRequestHandler.TRACKER_HOMES = {'demo': home}
283+
httpd = BaseHTTPServer.HTTPServer((hostname, port), RoundupRequestHandler)
284+
print 'Server running - connect to:\n %s'%url
285+
print 'You may log in as "demo"/"demo" or "admin"/"admin".'
286+
try:
287+
httpd.serve_forever()
288+
except KeyboardInterrupt:
289+
print 'Keyboard Interrupt: exiting'
290+
291+
if __name__ == '__main__':
292+
if len(sys.argv) > 1 and sys.argv[1] == 'demo':
293+
install_demo()
294+
else:
295+
main()
296+
221297
# vim: set filetype=python ts=4 sw=4 et si

0 commit comments

Comments
 (0)