mirror of
https://github.com/darksaid98/yolks.git
synced 2026-12-01 14:38:59 +00:00
fix(apps): mediawiki tweaks
This commit is contained in:
1 file changed
+66
-1
@@ -1,10 +1,75 @@
|
||||
FROM --platform=$TARGETOS/$TARGETARCH mediawiki:1.42.4
|
||||
FROM --platform=$TARGETOS/$TARGETARCH php:8.1-fpm
|
||||
|
||||
LABEL org.opencontainers.image.source="https://github.com/darksaid98/yolks"
|
||||
LABEL author="darksaid98" maintainer="[email protected]"
|
||||
|
||||
ENV DEBIAN_FRONTEND noninteractive
|
||||
|
||||
# System dependencies
|
||||
RUN set -eux; \
|
||||
\
|
||||
apt-get update; \
|
||||
apt-get install -y --no-install-recommends \
|
||||
git \
|
||||
librsvg2-bin \
|
||||
imagemagick \
|
||||
# Required for SyntaxHighlighting
|
||||
python3 \
|
||||
; \
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# Install the PHP extensions we need
|
||||
RUN set -eux; \
|
||||
\
|
||||
savedAptMark="$(apt-mark showmanual)"; \
|
||||
\
|
||||
apt-get update; \
|
||||
apt-get install -y --no-install-recommends \
|
||||
libicu-dev \
|
||||
libonig-dev \
|
||||
liblua5.1-0-dev \
|
||||
; \
|
||||
\
|
||||
docker-php-ext-install -j "$(nproc)" \
|
||||
calendar \
|
||||
intl \
|
||||
mbstring \
|
||||
mysqli \
|
||||
opcache \
|
||||
; \
|
||||
\
|
||||
pecl install APCu-5.1.24; \
|
||||
pecl install LuaSandbox-4.1.2; \
|
||||
docker-php-ext-enable \
|
||||
apcu \
|
||||
luasandbox \
|
||||
; \
|
||||
rm -r /tmp/pear; \
|
||||
\
|
||||
# reset apt-mark's "manual" list so that "purge --auto-remove" will remove all build dependencies
|
||||
apt-mark auto '.*' > /dev/null; \
|
||||
apt-mark manual $savedAptMark; \
|
||||
ldd "$(php -r 'echo ini_get("extension_dir");')"/*.so \
|
||||
| awk '/=>/ { so = $(NF-1); if (index(so, "/usr/local/") == 1) { next }; gsub("^/(usr/)?", "", so); printf "*%s\n", so }' \
|
||||
| sort -u \
|
||||
| xargs -r dpkg-query --search \
|
||||
| cut -d: -f1 \
|
||||
| sort -u \
|
||||
| xargs -rt apt-mark manual; \
|
||||
\
|
||||
apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
|
||||
|
||||
# set recommended PHP.ini settings
|
||||
# see https://secure.php.net/manual/en/opcache.installation.php
|
||||
RUN { \
|
||||
echo 'opcache.memory_consumption=128'; \
|
||||
echo 'opcache.interned_strings_buffer=8'; \
|
||||
echo 'opcache.max_accelerated_files=4000'; \
|
||||
echo 'opcache.revalidate_freq=60'; \
|
||||
} > /usr/local/etc/php/conf.d/opcache-recommended.ini
|
||||
|
||||
RUN apt -y update && \
|
||||
apt -y upgrade && \
|
||||
apt -y install iproute2 && \
|
||||
|
||||
Reference in new issue
Block a user