At work we have a lot of information that needs to be documented (for internal use). This information ranges from our coding standards documentation, to schema change documentation, to designs, employee phone-lists, etc… In the beginning we had a bunch of scatter word documents. Pretty much this meant nobody actually read the documents because nobody could find them. Then (years ago) Kyle installed a python based wiki on our Linux box (NEO) and it revolutionized everything. Then NEO died and was never rebuilt. Back to word documents.
About a month ago Tony revived the wiki idea and installed some crazy .NET based wiki on an IIS machine here. It took an awful lot of work but in the end it worked pretty well. It definitely was not particularly polished but it worked. Then Tony noticed that Media Wiki, the wiki software that powers wikipedia is available for free (PHP/MySQL based) so we thought we’d try that out as it looked much more polished and much more powerful.
We also have been running an internal Jabber server on my machine so this sounded like a good idea to move that onto a dedicated machine.
So anyways to make a long store short we decided to setup a Linux machine (I demanded Debian and won). We didn’t have a spare machine to give but we do have a really fast machine running VMWare (for our builds) so we just made a new VM on there. We configured it to have a 4GB disk image, 128M ram and attached the CD to the Debian Net install CD image and we booted it up.
The debian installer worked absolutely perfectly. We pretty much walked through and chose defaults all the way through. The network was configured with DHCP (the VM was setup to use bridged networking), the drive auto-partitioned, etc. It just worked. When the install finished we chose “Manual Package Selection” when asked what we would use the machine for and then bailed out of aptitude so that we had a bare minimum machine.
Now it was just installing the server software. I wanted SSH for remote administration, the jabber server, and apache, mysql and php for the wiki.
$apt-get install ssh apache mysql-server libapache-mod-php4 php4-mysql jabber
That installed all the required software.
Configuring jabber consisted entirely of opening /etc/jabber/jabber.xml and changing the hostname to the system hostname.
We downloaded the MediaWiki tarball and untarred it into the Apache docroot /var/www. Reading the instructions we then had to make the config directory writable and the wiki’s installer would do the rest.
$ cd /var/www
$ tar --strip-path 1 -xzvf /tmp/mediawiki-1.4.0.tar.gz
$ chmod a+w config
Now you go to http://127.0.0.1 in the browser and get the MediaWiki config page which asks for the Wiki name and database information. It’ll even create the database and a user for the MediaWiki if you provide the MySQL root user name/password (which is just root and empty password since it’s still defaults). Press the go button and it created LocalSettings.php in the config/ directory. Just move that file into /var/www and remove config and we’re done.
$ cd /var/www
$ mv config/LocalSettings.php .
$ rm -rf config/
Finally to enable image/media uploads you have to make the images folder writable and remove the /images alias from the Apache config file.
$ chmod a+w /var/www/images
And in /etc/apache/httpd.conf. Comment out the “Alias /images/ /usr/share/images/” line.
And that was it. The whole process took less than an hour and we have a jabber server and very fancy wiki system. Tony and I were stunned at how it just worked. We didn’t run into a single snag.