Инструменты пользователя

Инструменты сайта

  • Показать исходный текст
  • История страницы
  • Ссылки сюда
  • Оставить на чай
  • Экспорт в PDF
  • Наверх

  • wiki:install:ubuntu

    Руководство по установке

    Выполните в терминале:

    sudo apt-get install dokuwiki

    Устраним проблемы, которые могут помешать нам запустить установщик DokuWiki в браузере:

    sudo nano /etc/apache2/conf.d/dokuwiki.conf

    в убунту 16 это

     sudo nano /etc/dokuwiki/apache.conf

    найдите строку

    Alias /dokuwiki /usr/share/dokuwiki/

    Теперь удалите слэш, следующий после /usr/share/dokuwiki. После этого файл должен содержать только:

    Alias /dokuwiki /usr/share/dokuwiki

    Нажмите ctrl-X для выхода из редактора и нажмите Y для сохранения. Теперь перезапустим Apache2 :

    sudo /etc/init.d/apache2 restart

    Вы почти готовы идти дальше. Посетите: http://localhost/dokuwiki/doku.php
    Remember, that default configuration prevents you from visiting you dokuwiki outside localhost.

    The initial DokuWiki setup is actually done when DokuWiki is installed. Если вы хотите вернуть первоначальные настройки (http://localhost/dokuwiki/install.php) вы должны сделать следующее:

    sudo chown -R www-data /usr/share/dokuwiki/conf/
    sudo rm /usr/share/dokuwiki/conf/users.auth.php
    sudo rm /usr/share/dokuwiki/conf/acl.auth.php
    sudo nano /usr/share/dokuwiki/install.php

    Найдите следующие строки кода:

      // main dokuwiki config file (conf/dokuwiki.php) must not have been modified
      $installation_hash = md5(preg_replace("/(\015\012)|(\015)/","\012",
                               @file_get_contents(DOKU_CONF.'dokuwiki.php')));
      if (!in_array($installation_hash, $dokuwiki_hash)) {
            $error[] = sprintf($lang['i_badhash'],$installation_hash);
            $ok = false;
        }

    Замените

    $ok = false;

    на

    $ok = true;

    Run the initial configuration with

    http://localhost/dokuwiki/install.php

    Alternative Easier Custom Installation

    The version of DokuWiki that comes with Ubuntu is generally slightly older. Installing it via the package manager also does not seem to work very well. You can easily install the latest version by following these steps (tested on Ubuntu 9.04):

    • Make sure you have apache2 and PHP installed. If you do not have those up already, there are lots of instructions for installing them. You can test if you have Apache installed by navigating your browser to http://localhost/
    • Make sure you have the utility wget installed. Run the Synaptic Package Manager (click System, Administration, Synaptic Package Manager) and search for wget. It is very small so it is quick to install.
    • Go to the DokuWiki downloads page and get the link for the version you want to use. It will be something like: http://www.splitbrain.org/_media/projects/dokuwiki/dokuwiki-2010-11-07.tgz

    Now click Applications, Accessories, Terminal. Then enter these commands:

    cd /var/www
    sudo wget http://www.splitbrain.org/_media/projects/dokuwiki/dokuwiki-2010-11-07.tgz
    sudo tar xvf dokuwiki-2010-11-07.tgz
    sudo mv dokuwiki-2010-11-07 dokuwiki
    sudo chown -R www-data:www-data /var/www/dokuwiki

    The last line is the bit of magic that will fix the write and access permissions and make apache2 find the files. Incidentally, nearly the same recipe can be successfully used to install other Apache applications such as Joomla, Drupal, etc. Needless to say, update the above command by changing the names slightly if you choose to download a different version of DokuWiki.

    If you do not have wget, simply click in your browser to download the the DokuWiki file. Then do this:

    cd /var/www
    sudo mv /home/USER/Desktop/dokuwiki-2009-12-25c.tgz .
    (Now continue on with the tar command above)

    Now you should be able to navigate to http://localhost/dokuwiki/install.php

    With this approach the package manager will not show DokuWiki as installed. To uninstall it again completely, do this:

    cd /var/www
    sudo rm -r -f dokuwiki
    Только авторизованные участники могут оставлять комментарии.
    wiki/install/ubuntu.txt · Последнее изменение: 2024/08/15 01:09 — vladpolskiy