Python Community Server
=======================
         --> alpha test v0.12
         
 -^--------^--      
/   \      /  \    -----------
|    O     O   |  / read me   \
|       V      | C   hellooo~  |
\             /   \   hoo hoo /
 / \        / \    -----------
|\  \      /  /|
| \  \    /  / |
|  ^^^    ^^^  |
 \__  ____  __/
    vv    vv

PyCS is still "unstable".  That means it's perfectly suitable to use for your 
weblog community server (it's been running http://www.pycs.net/ and some others 
quite happily for a fair while now) but it may require some hacking to get it to 
work on your system.

Here are some notes to get you going.  First, you'll want to read the setup howto:

	http://www.myelin.co.nz/wcswiki/w/PythonCommunityServer



DEPENDENCIES
	
	Medusa - http://www.nightmare.com/medusa/

		The docs are at the above URL, but you want to download the newer
		version from SourceForge:

		http://oedipus.sourceforge.net/medusa/
	
		Unpack this into a subdirectory of your PyCS directory called
		'medusa'.  When you run 'make install' it will be saved into
		/usr/lib/pycs/bin/medusa.
	
	
	MetaKit - http://www.equi4.com/metakit/python.html
	
		Install this as usual.  Put Mk4py.so and metakit.py into your 
		PyCS dir if it doesn't work.


NOTES

	Installation:
	
		The PyCS page on the Community Server Wiki has the most up-to-
		date information here.  See also the linked setup HOWTO.
		
			http://www.myelin.co.nz/wcswiki/w/PythonCommunityServer
		
	
	Virtual Hosting:
	
		If you already have a copy of Apache running on your box and 
		want PyCS to only serve requests for a certain (virtual) host or 
		group of hosts, you can accomplish this with mod_rewrite and 
		mod_proxy.
		
		Put the following in your VirtualHost block:
	
			RewriteEngine On
			RewriteRule ^(.+) http://127.0.0.1:5445/~~vhost~~/%{HTTP_HOST}$1 [P]
		
		This way, Apache will send the requested hostname through to the 
		PyCS server, allowing it to work out virtual hosts on its own. 
		See /etc/pycs/rewrite.conf for more info on how to do this.
		
		Here's a more complete example of a VirtualHost block that 
		proxies requests through to a PyCS server.
		
		
		        DocumentRoot /var/www/external
		        ServerAlias pycs.net *.pycs.net
		        ServerName pycs.net
		
		        ErrorLog /var/log/apache/rcs-error.log
		        CustomLog /var/log/apache/rcs-access.log combined
		
		        RewriteEngine On
			RewriteRule ^(.+) http://127.0.0.1:5445/~~vhost~~/%{HTTP_HOST}$1 [P]
		
		
		This tells Apache that requests for pycs.net and *.pycs.net
		should be sent through to the PyCS using the ~~vhost~~ syntax
		(see rewrite.conf for more info), and that logging should go
		to /var/log/apache/rcs-{error,access}.log.
		
	
	Security:
	
		You'll want to run PyCS as an unprivileged user.  'make install' 
		will create a www-pycs account for you and put everything in the 
		right places.

		Once you've started the server, run 'ps auxf' and check that 
		/usr/bin/python /var/lib/pycs/bin/pycs.py is not running as 
		root.  It should be 'www-pycs' or the user you specified on 
		installation.
	

	Logging:
	
		It writes three log files in /var/log/pycs: access.log, etc.log 
		and error.log. etc.log logs everything written to stdout and 
		error.log logs everything written to stderr, while access.log 
		logs hits and stuff - what you might expect to see from a basic 
		Apache access.log.
		
		The referrer tracking code writes a log file per blog in the 
		same directory to track the hits in the last 24 hours.  The 
		format here is slightly different; see /system/count.py and 
		/system/referers.py for more information.


CONCLUSION

	If anyone wants to fix anything or add features, go ahead!
	
	BUT: join the mailing list and announce what you're about to do first, 
	so everyone else knows not to work on the same thing.

	Details here:

		http://lists.sourceforge.net/lists/listinfo/pycs-devel

	Cheers,
		Phil 



OFFICIAL WEB PAGES

	Project:

		http://www.pycs.net/
		http://pycs.sourceforge.net/

	Community Servers in general:

		http://www.myelin.co.nz/wcswiki/


CREDITS

	All original code, search integration:
	
		Phillip Pearson, pp at myelin dot co dot nz

		http://www.myelin.co.nz/post/
		http://www.myelin.co.nz/crash/
		http://www.pycs.net/devlog/
		http://www.pycs.net/ (English community server)
	
	Referrer tracking and hit counting, pretty much everything since late 2002:
	
		Georg Bauer, gb at murphy dot bofh dot ms

		http://pyds.muensterland.org/		
		http://hugo.muensterland.org/
		http://muensterland.org/ (German community server)

	Internationalization:

		Yasushi Iwata

		http://lowlife.jp/yasusii/
		http://lowlife.jp/ (Japanese community server)
	
	Daemonizing:
	
		Michael Hay, Michael dot Hay at hds dot com
	
	Password changing:
	
		Scott Lewis, scott at bandwidthcoop dot org
		
		http://www.pycs.net/scott/