This is an old revision of the document!
This page describe the installation of DokuWiki (version 2010-11-07).
Dokuwiki needs Apache and PHP. I personnaly use the following Debian packages :
For more details, look at Web Server (Apache)
Dokuwiki can installed from the Debian repository or directly from the sources.
I do prefer the manual installation because there is no risk of automatic upgrade from Debian.
Install the package :
During the install, choice the subdirectory of the website, for example /wiki.
The default configuration gives already a working wiki available locally (for remote access you need to change the apache configuration, see bellow).
By default, the directories used are :
By default, with apache2, dokuwiki is defined by the file /etc/dokuwiki/apache.conf. Only 127.0.0.1 is allowed.
To make the website available to everybody, you need to modify the “allow from” :
Alias /dokuwiki /usr/share/dokuwiki <Directory /usr/share/dokuwiki/> Options +FollowSymLinks AllowOverride All order allow,deny # allow from 127.0.0.1 allow from all </Directory>
The restart apache to apply the change.
Sources are available at http://www.splitbrain.org/projects/dokuwiki
Unzip the sources to the directory of your choice, for example /opt/dokuwiki/ :
:/opt# tar -zxvf /root/dokuwiki-2008-05-05.tgz dokuwiki-2008-05-05/ dokuwiki-2008-05-05/.htaccess.dist dokuwiki-2008-05-05/README dokuwiki-2008-05-05/index.php dokuwiki-2008-05-05/install.php dokuwiki-2008-05-05/COPYING dokuwiki-2008-05-05/doku.php dokuwiki-2008-05-05/VERSION dokuwiki-2008-05-05/bin/ dokuwiki-2008-05-05/bin/.htaccess dokuwiki-2008-05-05/bin/indexer.php .... :/opt# mv dokuwiki-2008-05-05/ dokuwiki :/opt# l total 4 drwxr-xr-x 7 matthieu Debian-exim 4096 2008-05-05 19:10 dokuwiki :/opt#
You need to apply the following rights :
Example :
:/opt# chown -R matthieu:matthieu dokuwiki/ :/opt# chown matthieu:www-data dokuwiki/ :/opt# chmod 750 dokuwiki/ :/opt# cd dokuwiki/ :/opt/dokuwiki# chown -R www-data data/ :/opt/dokuwiki# chown www-data conf/ :/opt/dokuwiki# chown www-data lib/plugins/ :/opt/dokuwiki# l total 92 drwxr-xr-x 2 matthieu matthieu 4096 7 nov. 17:43 bin drwxr-xr-x 2 www-data matthieu 4096 7 nov. 17:43 conf -rw-r--r-- 1 matthieu matthieu 17992 7 nov. 17:43 COPYING drwxr-xr-x 10 www-data matthieu 4096 7 nov. 17:43 data -rw-r--r-- 1 matthieu matthieu 2185 7 nov. 17:43 doku.php -rw-r--r-- 1 matthieu matthieu 11730 7 nov. 17:43 feed.php -rw-r--r-- 1 matthieu matthieu 1526 7 nov. 17:43 .htaccess.dist drwxr-xr-x 6 matthieu matthieu 4096 7 nov. 17:43 inc -rw-r--r-- 1 matthieu matthieu 182 7 nov. 17:43 index.php -rw-r--r-- 1 matthieu matthieu 17428 7 nov. 17:43 install.php drwxr-xr-x 9 matthieu matthieu 4096 7 nov. 17:43 lib -rw-r--r-- 1 matthieu matthieu 306 7 nov. 17:43 README -rw-r--r-- 1 matthieu matthieu 22 7 nov. 17:43 VERSION :/opt/dokuwiki# l lib/ total 32 drwxr-xr-x 2 matthieu matthieu 4096 7 nov. 17:43 exe drwxr-xr-x 2 matthieu matthieu 4096 7 nov. 17:43 _fla drwxr-xr-x 8 matthieu matthieu 4096 7 nov. 17:43 images -rw-r--r-- 1 matthieu matthieu 376 7 nov. 17:43 index.html drwxr-xr-x 9 www-data matthieu 4096 7 nov. 17:43 plugins drwxr-xr-x 2 matthieu matthieu 4096 7 nov. 17:43 scripts drwxr-xr-x 2 matthieu matthieu 4096 7 nov. 17:43 styles drwxr-xr-x 3 matthieu matthieu 4096 7 nov. 17:43 tpl :/opt/dokuwiki# l .. total 12 drwxr-x--- 7 matthieu www-data 4096 7 nov. 17:43 dokuwiki :/opt/dokuwiki#
When installing dokuwiki from the source, Apache need to be configured manually.
For example, create the following file in /etc/apache2/sites-available/dokuwiki :
Alias /wiki /opt/dokuwiki <Directory /opt/dokuwiki/> Options +FollowSymLinks AllowOverride All order allow,deny allow from all </Directory>
Then activate it :
:/etc/apache2/sites-available# vi dokuwiki :/etc/apache2/sites-available# a2ensite dokuwiki Site dokuwiki installed; run /etc/init.d/apache2 reload to enable. :/etc/apache2/sites-available# /etc/init.d/apache2 reload Reloading web server config...7058 . :/etc/apache2/sites-available#
Dokuwiki should be available on the /wiki.
By default Dokuwiki is a open wiki writable by everyone without authentication.
To configure it, there is an install page : install.php.
For example : http://www.monsite.fr/wiki/install.php.
The conf directory needs to be writable by www-data.
Please select the following fields :
www.bouthors.fr is a “Public Wiki”.
Once you log in as admin, you can change the options inside “Admin » Configuration Manager”
Here are some values used for this website :
<?php /* * Dokuwiki's Main Configuration File - Local Settings * Auto-generated by config plugin * Run for user: matthieu * Date: Sun, 02 Jan 2011 23:14:53 +0100 */ $conf['title'] = 'www.bouthors.fr'; $conf['lang'] = 'fr'; $conf['license'] = 'cc-by-sa'; $conf['breadcrumbs'] = 5; $conf['youarehere'] = 1; $conf['useheading'] = '1'; $conf['useacl'] = 1; $conf['superuser'] = '@admin'; $conf['disableactions'] = 'register'; $conf['sneaky_index'] = 1; // end auto-generated content