Created
March 9, 2018 14:37
-
-
Save thisismattmiller/1a91e498db6aeb4672993a828868fec5 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM ubuntu as fetcher | |
RUN apt-get update && \ | |
apt-get install --yes --no-install-recommends unzip | |
ADD https://github.com/wikimedia/mediawiki-extensions-Wikibase/archive/REL1_30.zip . | |
# Creates /mediawiki-extensions-Wikibase-REL1_30 | |
RUN unzip REL1_30.zip && rm *.zip | |
FROM composer as composer | |
COPY --from=fetcher /mediawiki-extensions-Wikibase-REL1_30 /Wikibase | |
RUN cd /Wikibase && composer install --no-dev | |
FROM mediawiki:1.30 | |
# Install envsubst | |
RUN apt-get update && \ | |
DEBIAN_FRONTEND=noninteractive apt-get install --yes --no-install-recommends gettext-base && \ | |
rm -rf /var/lib/apt/lists/* | |
RUN a2enmod rewrite | |
RUN install -d /var/log/mediawiki -o www-data | |
COPY --from=composer /Wikibase /var/www/html/extensions/Wikibase | |
COPY wait-for-it.sh /wait-for-it.sh | |
COPY entrypoint.sh /entrypoint.sh | |
COPY LocalSettings.php.template /LocalSettings.php.template | |
COPY htaccess /var/www/html/.htaccess | |
COPY --chown=www-data logo_135x135.png /var/www/html/logo.png | |
RUN ln -s /var/www/html/ /var/www/html/w | |
ENV DB_SERVER=mysql.svc:3306\ | |
DB_USER=wikiuser\ | |
DB_PASS=sqlpass\ | |
DB_NAME=my_wiki\ | |
MW_SITE_NAME=wikibase-docker\ | |
MW_SITE_LANG=en\ | |
MW_ADMIN_NAME=admin\ | |
MW_ADMIN_PASS=adminpass | |
ENTRYPOINT ["/bin/sh"] | |
CMD ["/entrypoint.sh"] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment