SystemComponent "Semantic MediaWiki"

From FindAndLearn::Cookbook
C1470408196
Jump to: navigation, search


dataspects recommends https://www.semantic-mediawiki.org as its wiki component.

CanBeInstalled Yes[edit | edit source]

HasLastProcessValidationStamp 190218byLex

Versioning | docker exec

Step 1: Prepare Docker containers and volumes[edit | edit source]

  1. Setup "Dockerized dataspectsSystem"

Step 2: Get software and set permissions[edit | edit source]

  1. [email protected]:/var/lib/docker/volumes/<VOLUME>/_data$ git clone -b REL1_31 --depth 1 --single-branch https://github.com/wikimedia/mediawiki.git w/
  2. [email protected]:/var/lib/docker/volumes/<VOLUME>/_data/w$ git submodule update --init --recursive
  3. [email protected]:/var/lib/docker/volumes/<VOLUME>/_data/w$ chown -R www-data .
  4. Install PHP Composer:
  5. [email protected]:/var/lib/docker/volumes/<VOLUME>/_data/w$ docker exec --user www-data <container> bash -c "cd /var/www/html/w && php composer.phar install"
    • This will currently cause Cannot create cache directory /var/www/.composer/cache/repo/https---repo.packagist.org/, or directory is not writable. Proceeding without cache. Cannot create cache directory /var/www/.composer/cache/files/, or directory is not writable. Proceeding without cache.

Step 3: Configure and run MediaWiki installation script[edit | edit source]

  1. Place a copy of https://github.com/dataspects/dataspectsSystem/blob/master/ansible_templates/install_mediawiki.sh.j2 as /var/lib/docker/volumes/<VOLUME>/_data/w/install_mediawiki.sh
  2. Configure /var/lib/docker/volumes/<VOLUME>/_data/w/install_mediawiki.sh
  3. [email protected]:/var/lib/docker/volumes/<VOLUME>/_data/w$ chmod +x install_mediawiki.sh
  4. [email protected]:/var/lib/docker/volumes/<VOLUME>/_data/w$ docker exec --user www-data <container> bash -c "cd /var/www/html/w && ./install_mediawiki.sh"

Step 4: Add fundamental settings to LocalSetting.php[edit | edit source]

 $wgArticlePath = '/wiki/$1';
 $wgServer = "???";
 $wgEnableUploads = true;

Step 5: Configure and run MediaWiki extensions installation[edit | edit source]

  1. Place copies of:
  2. Configure /var/lib/docker/volumes/<VOLUME>/_data/w/mediawiki_extensions.yml
  3. [email protected]:/var/lib/docker/volumes/<VOLUME>/_data/w$ ruby install_mediawiki_extensions.rb