Ubuntu is a port of Debian and therefore the issues that arise for either often have the same answers; differences will be noted.
The package manager is either the command line tool apt-get or the GUI Synaptic Package Manager. One problem with the package manager is that its distributions of Dokuwiki can be behind the Dokuwiki distribution schedule. The Debian package is currently being upgraded to Angua and so one assumes that Ubuntu will follow.1)
The package manager creates its own file structure for Dokuwiki.
/etc/dokuwiki /usr/share/dokuwiki /var/lib/dokuwiki
/usr/share/dokuwiki holds three subdirectories:
bininclibdata, which points to /var/lib/dokuwikiconf which points to /etc/dokuwiki
/var/lib/dokuwiki contains the following subdirectories:
acl, which contains the acl filesdata, which is the standard Dokuwiki data sectionplugins, the plugins directorytpl, the template directoryThe default settings are very restrictive. The package manager sets up a wiki which has only localhost access and where only root can make any changes to the configuration settings and only root can install plugins. The administrator cannot use the Dokuwiki administration facilties which are normally accessed from the admin button. Also, by default the administrator's userid is 'admin'. In the Debian setup, the package manager asks for an administrator password; on Ubuntu it does not.
The default settings can be modified from the command line using the command line tool dpkg-reconfigure:
sudo dpkg-reconfigure dokuwiki
You can run this tool after the initial install and change the settings to your requirements. For more information on this tool and on the default settings, see the debian installation instructions. To run this program, it should be noted, you must open a copy of the terminal.
You do not have to use the package manager to install Dokuwiki. Instead you can download the latest Dokuwiki and follow the Dokuwiki installation instructions. This will give you a standard installation with the usual options and features. See dokuwiki.
If you want to make your wiki fully conform to the Dokuwiki security settings, you will have to make a change to the apache configuration file. The apache configuration files are found in /etc/apache2. The one you want to modify is: /etc/apache2/sites-enabled/000-default which is a link to /etc/apache2/sites-available/default. The default settings for apache cause the server to ignore the .htaccess files which Dokuwiki relies on. This is the section of 000-default that you would be most interested in:
<Directory /var/www/> Options Indexes FollowSymLinks MultiViews AllowOverride None Order allow,deny allow from all </Directory>
The AllowOverride None causes the web server to ignore all .htaccess files and Dokuwiki relies on .htaccess files to implement its security. This should be changed to AllowOverride All. There are other settings for AllowOverride, which are detailed in the Apache documentation, but there is generally no danger to using all.
Another reason for enabling .htaccess files is that without reference to .htaccess, you cannot create Dokuwiki nice urls using the htaccess option.
Once you have made the change to 000-default, you will have to restart the apache web server. For this you must open the terminal program and at the command line enter the following command:
sudo service apache2 restart
Dokuwiki comes with a distribution copy of the .htaccess file called .htaccess.dist. In the package manager installation, this file will be found in /etc/dokuwiki; in the standard Dokuwiki install it will be found in your top-level dokuwiki directory. Copy this file to .htaccess. Then uncomment all of the commented-out lines except for the https and and xmlrpc entries; you may want to enable these features at a later time but leave them alone initially. Commented lines begin with a hash (number sign), as in:
#RewriteEngine on
Remove the hash to uncomment the line:
RewriteEngine on
Uncommenting the lines will create a set of substitutions which the web server will make in order to format nice urls.
The next thing you need to do is to enable apache's rewrite module. Again from the command line:
sudo a2enmod rewrite
This will update the configuration files; then you must restart the server:
sudo service apache2 restart
It should be noted that if ever the service command does not work, you can do the same with this command:
sudo /etc/init.d/apache2 restart
You must always use sudo with these commands because they require root user access.