This file is a step-by-step how to for install and set up CodingTeam on your own server. Before read this document, you should install all dependencies listed in the README file. ***************************** 1. Apache configuration ***************************** You have to set up a VirtualHost for CodingTeam like this example: NameVirtualHost *:80 ServerName www.example.org DocumentRoot "/path/to/codingteam" AllowOverride All php_flag engine off AllowOverride None Options -Indexes Options +Indexes ErrorLog /var/log/apache2/error.log LogLevel warn CustomLog /var/log/apache2/access.log combined ServerSignature On Now, you have to set up another VirtualHost for SVN repositories like this one: ServerName svn.example.org include /path/to/codingteam/public/svn/_apache/* ErrorLog /var/log/apache2/error.log LogLevel warn CustomLog /var/log/apache2/access.log combined This means that the configuration for subversion repositories will be loaded automatically at each reboot of the HTTPD server (see the section 4). Also, please be sure that mod_rewrite is activated. ***************************** 2. Folders owners and rights ***************************** First of all, directories inc/modules must be writable by CodingTeam (in order to enable and disable modules and views). This is not mandatory but this is required to configure the modules directly from CodingTeam. Basically, you can do a: $ chown www-data:root -R inc/modules/ && chmod 777 -R inc/modules/ Now, you have to create some directories in the public/ one. All have to be writable by PHP, so, you must do a chmod 770 and set the owner www-data:root: public/cache → public/cache/atom → public/cache/rss → public/cache/xhtml public/upload → public/upload/avatars → public/upload/projects For Subversion integration, you must create following directories. This allows CodingTeam to create subversion repositories in the public/svn paths. Apache configurations are stored in public/svn/_apache and authentification files in public/svn/_authz. Just recursively set the owner www-data:root on this directory. public/svn → public/svn/_apache → public/svn/_authz If you want, you can create a folder for the logs of all Jabber rooms. This folder must be readable by Apache, but not writable. public/muclogs ***************************** 3. CodingTeam configuration ***************************** CodingTeam use a XML-based configuration. There is an example in inc/codingteam.cfg-example. Start by rename it: $ mv codingteam.cfg-example codingteam.cfg Now, you can start to write your config (your XML-base file have to be conform to the XSD XMLSchema). Here a little explanations of the possibles values: db->type: The software that run the database There are 2 database software supported: * for MySQL 5.x: `mysql` * for PostgreSQL: `pgsql` EXPERIMENTAL db->hostname: The hostname of your mysql base db->database: The name of the database db->username: The name of the user db->password: The password of the user svn->subdomain: Subdomain for SVNs (second VirtualHost example) svn->location: Text between subdomain and project name (default: /) Now, you are ready to import the SQL shema in your database with codingteam.sql! When the shema is imported, you should follow this end step to add a minimal configuration for CodingTeam: INSERT INTO `config` (`group`, `field`, `value`, `text`) VALUES ('global', 'mailfrom', 'MyForgeName ', 'The FROM and REPLYTO headers of sended mail.'), ('global', 'cache-max-files', '2000', 'The maximum files number for the cache.'), ('global', 'slogan', 'Create. Participate. Evolve. Free Software.', 'The slogan of your forge.'), ('jabber', 'omnipresence-jid', 'presence.jabberfr.org', 'The Jabber ID of the Omnipresence bot.'), ('jabber', 'omnipresence-url', 'http://presence.jabberfr.org/', 'The HTTP URL of the Omnipresence bot.'), ('jabber', 'server', 'domain.net', 'The domain of the jabber server.'), ('jabber', 'muc', 'conference.domain.net', 'The Jabber ID of the conference component.'), ('jabber', 'username', 'username', 'The username of the bot.'), ('jabber', 'password', 'password', 'The password of the bot.'), ('jabber', 'nickname', 'nickname', 'The nickname of the bot.'), ('openforge', 'esearch-active', 'true', 'true or false if you want to active external search.'), ('openforge', 'esearch-servers', '', 'A list of external servers, separated by a ";".'), ('projects', 'need-validate', 'true', 'true or false if you want to validate all new projects.'), ('projects', 'allow-adding', 'true', 'true or false if you want to disable projects adding.'), ('projects', 'allow-donation', 'true', 'true or false if you want to disable projects donation.'), ('users', 'allow-registration', 'true', 'true or false if you want to disable users registration.'); By default, omnipresence-jid and omnipresence-url are already sets because it's the only Omnipresence server we know. Omnipresence allows CodingTeam to retrieve the avatar of a member via his Jabber account and some great features like that. You could install your own Omnipresence and use it instead of the JabberFR ones. See: http://www.codingteam.net/project/omnipresence Now, you have to configure MUCKl (the web-based client for Jabber chatrooms). There are 2 files to edit in inc/libs/muckl, start by rename them: $ mv config.js-example config.js && mv .htaccess-example .htaccess In config.js, you should set XMPPDOMAIN and MUCSERVER (at lines 52-53). XMPPDOMAIN is the equivalent of `jabber.server` and MUCSERVER of `jabber.muc` (see above). In .htaccess, you should edit the URL to your Jabber server at line 9. Note that HTTP polling needs some configuration on the server-side. Additionaly, you need to enable 3 Apache modules: - proxy - proxy_connect - proxy_http You can now start Apache and discover your new forge. :) ***************************** 4. CodingTeam maintenance ***************************** At this step, CodingTeam is ready to work on your server. You need to restart the HTTPD server each time you add a subversion repository. That's why scripts/miscellaneous/ contains the server-maintenance Shell script. CodingTeam propose to restart HTTPD server all days at midnight. You can add a similar rule to your crontab (as root): 0 0 * * * /path/to/codingteam/scripts/miscellaneous/server-maintenance