grim/containers/imfwiki

Update to mediawiki 1.31.3
draft
2020-09-02, Gary Kramlich
205fe0c2cd16
Update to mediawiki 1.31.3
FROM mediawiki:1.31.3
#FROM mediawiki:stable
# Secure the upload directory
COPY conf-enabled/ /etc/apache2/conf-enabled/
# install unzip as composer wants it
RUN set -ex && \
apt-get update && \
apt-get install -y --no-install-recommends unzip && \
apt-get clean && \
rm -rf /var/lib/apt/lists
# install composer as one of our extensions needs it
RUN set -ex && \
cd /usr/local/bin && \
php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" && \
php -r "if (hash_file('sha384', 'composer-setup.php') === '8a6138e2a05a8c28539c9f0fb361159823655d7ad2deecb371b04a83966c61223adc522b0189079e3e9e277cd72b8897') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;" && \
php composer-setup.php && \
php -r "unlink('composer-setup.php');"
# now install the mediawiki extensions we want
RUN set -ex && \
cd /var/www/html/extensions && \
git clone https://github.com/Schine/MW-OAuth2Client.git && \
cd MW-OAuth2Client && \
git submodule update --init && \
cd vendors/oauth2-client && \
composer.phar install --no-dev --no-cache --prefer-dist
# add a /config directory and point a symlink to a LocalSettings.php file which
# is volume mounted in at run time.
RUN set -ex && \
mkdir -p /config && \
ln -s /config/LocalSettings.php /var/www/html/LocalSettings.php