58 lines
2.2 KiB
Docker
58 lines
2.2 KiB
Docker
# Install standardized extensions into the official mediawiki container.
|
|
# Ensure my modified language-data, UniveralLanguageSelector, and jquery.uls
|
|
# code is installed, such that the shavian script is included.
|
|
|
|
FROM mediawiki:1.42
|
|
|
|
# Extensions are placed in subdirectories under the /var/www/html/extensions
|
|
# directory in the container. This can be overridden if some other container
|
|
# is used as the base.
|
|
ARG EXT_BASE=/var/www/html/extensions
|
|
ARG COMPOSER=composer.local.json
|
|
|
|
|
|
####
|
|
# Install composer
|
|
# ================
|
|
# Note that we need to just get the composer script directly rather than use
|
|
# Debian packages. The base image is Docker's php-apache library image, which
|
|
# builds PHP from source rather than install from Packages. Hence many
|
|
# required packages are missing (and should stay missing.)
|
|
####
|
|
RUN curl https://getcomposer.org/composer.phar -o /usr/bin/composer && \
|
|
chmod a+x /usr/bin/composer
|
|
|
|
|
|
#####
|
|
# Mediawiki Language Extension Bundle
|
|
# ===================================
|
|
# - Babel
|
|
# - CLDR
|
|
# - CleanChanges
|
|
# - Translate
|
|
# - UniversalLanguageSelector
|
|
#####
|
|
|
|
RUN composer require --no-update mediawiki/babel:2024.07 && \
|
|
composer require --no-update mediawiki/cldr:2024.07 && \
|
|
composer require --no-update mediawiki/translate:2024.07 && \
|
|
cd extensions && \
|
|
git clone --depth=1 --branch=REL1_42 https://github.com/wikimedia/mediawiki-extensions-CleanChanges.git CleanChanges && \
|
|
git clone --depth=1 --branch=shavian https://git.nordgren.vip/bryce/mediawiki-extensions-UniversalLanguageSelector.git UniversalLanguageSelector
|
|
|
|
|
|
#####
|
|
# Wikisource bundle prerequisites
|
|
# ===============================
|
|
#
|
|
# This is a partial deployment of this bundle. We exclude OCR related "ProofreadPage"
|
|
# and "Wikimedia OCR tool". We retain the ability to export pages to EPUB and pdf, and
|
|
# connect to Wikidata as a client.
|
|
#
|
|
# - WikibaseClient
|
|
# - WS Export (https://wikitech.wikimedia.org/wiki/Nova_Resource:Wikisource/Wikisource_Export)
|
|
# - connects to separate server running (https://github.com/wikimedia/ws-export/tree/main)
|
|
######
|
|
RUN cd extensions && \
|
|
git clone --depth=1 --branch=REL1_42 https://github.com/wikimedia/mediawiki-extensions-Wikibase.git Wikibase
|