Revision as of 11:48, 28 May 2013

zh-TW:Dokuwiki
"DokuWiki is a standards-compliant, simple-to-use wiki which allows users to create rich documentation repositories. It provides an environment for individuals, teams and companies to create and collaborate using a simple yet powerful syntax that ensures data files remain structured and readable outside the wiki."

"Unlimited page revisions allows restoration to any earlier page version, and with data stored in plain text files, no database is required. A powerful plugin architecture allows for extension and enhancement of the core system. See the features section for a full description of what DokuWiki has to offer."[1]

In other words, DokuWiki is a wiki written in PHP and requires no database.

Contents

Initial Notes

DokuWiki should work on any web server which supports PHP 5.1.2 or later. As the requirements may change over time, you should consult the requirements page for DokuWiki for additional details.

It is strongly recommend to read through the appropriate sections of DokuWiki's security page for your web server. Most popular web servers are covered but there are generic instructions as well.

The package in [community] unpacks DokuWiki at /srv/http/dokuwiki and changes ownership to the "http" user. This should work fine for most popular web servers as packaged for Arch.

Installation

Install your web server of choice (e.g. Apache or lighttpd) and configure it for PHP. As mentioned above, DokuWiki has no need for a database server so you may be able to skip those steps when setting up your web server.

With your web browser of choice, open http://<your-server>/dokuwiki/install.php and continue the installation from there.

Alternatively, if you would like to install from tarball, you can read from http://www.dokuwiki.org/Install. Generally the procedure is the same as above. Instead of using pacman, you will need to download the tarball, unpack it to your server's document root (e.g. /srv/http/dokuwiki), and chown to the appropriate user (e.g. "http").

Configuration

Apache

Firstly, create the file /etc/httpd/conf/extra/dokuwiki.conf with the following contents:

Include the newly created file in the Apache configuration by placing the following line at the end of /etc/httpd/conf/httpd.conf:

Include conf/extra/dokuwiki.conf

Make sure the folders /etc/webapps/dokuwiki and /var/lib/dokuwiki are owned by user and group "http". You may relocate these directories if you like as long as you update the references in /etc/httpd/conf/extra/dokuwiki.conf respectively.

Afterwards restart Apache:

# systemctl restart httpd.service

Then finish the installation by running the dokuwiki/install.php script in your browser.

lighttpd Specific Configuration

Edit the /etc/lighttpd/lighttpd.conf file as per the dokuwiki instructions (might contain updated information).

Post Installation

Cleaning Up

Installing Plugins

They can be added through the web interface (as well as updated) through the Admin menu. Some plugins cannot be downloaded, if they go over ssl (e.g. git). Uncomment following line in /etc/php/php.ini:

extension=openssl.so

Backing Up

It is very trivial to backup DokuWiki, since there is no database. All pages are in plain text, and require only a simple tar, or rsync.

A quick breakdown of the directories of interest in the current (2008-05-05) version: