From 33bf7f4cf5dad99ba9667e5b3adc0a992a53d222 Mon Sep 17 00:00:00 2001 From: itstimetoforget Date: Wed, 22 May 2024 20:58:09 +0200 Subject: [PATCH] fix --- .../build_and_push_docker_image/Dockerfile | 15 +++++++++++---- .../setup/install_plugins.sh | 10 ++++++++++ .../setup/install_skins.sh | 10 ++++++++++ 3 files changed, 31 insertions(+), 4 deletions(-) create mode 100644 actionfiles/build_and_push_docker_image/setup/install_plugins.sh create mode 100644 actionfiles/build_and_push_docker_image/setup/install_skins.sh diff --git a/actionfiles/build_and_push_docker_image/Dockerfile b/actionfiles/build_and_push_docker_image/Dockerfile index 972cf02..bbcde2a 100644 --- a/actionfiles/build_and_push_docker_image/Dockerfile +++ b/actionfiles/build_and_push_docker_image/Dockerfile @@ -18,11 +18,18 @@ RUN set -ex && \ # Define working directory for the following commands WORKDIR ${MW_ROOT} -# Copy Tweeki skin to skins/ -COPY ./skins/Tweeki skins/Tweeki +#install skins +COPY actionfiles/build_and_push_docker_image/setup/install_skins.sh . +RUN chmod +x install_skins.sh +RUN ./install_skins.sh +RUN rm ./install_skins.sh + +#install plugins +COPY actionfiles/build_and_push_docker_image/setup/install_plugins.sh . +RUN chmod +x install_plugins.sh +RUN ./install_plugins.sh +RUN rm ./install_plugins.sh -# Copy extensions -COPY ./extensions extensions # Copy the php.ini with desired upload_max_filesize into the php directory. COPY ./resources/php.ini /usr/local/etc/php/php.ini diff --git a/actionfiles/build_and_push_docker_image/setup/install_plugins.sh b/actionfiles/build_and_push_docker_image/setup/install_plugins.sh new file mode 100644 index 0000000..a653e1d --- /dev/null +++ b/actionfiles/build_and_push_docker_image/setup/install_plugins.sh @@ -0,0 +1,10 @@ +#versions +pdfembed_version=2.0.2 + +# https://www.mediawiki.org/wiki/Extension:PDFEmbed +if [ ! -d extensions/PDFEmbed ]; then + echo "Downloading PDFEmbed" + wget https://gitlab.com/hydrawiki/extensions/PDFEmbed/-/archive/${pdfembed_version}/PDFEmbed-${pdfembed_version}.zip + unzip PDFEmbed-${pdfembed_version}.zip + mv PDFEmbed-${pdfembed_version}/ extensions/PDFEmbed +fi \ No newline at end of file diff --git a/actionfiles/build_and_push_docker_image/setup/install_skins.sh b/actionfiles/build_and_push_docker_image/setup/install_skins.sh new file mode 100644 index 0000000..79e4eec --- /dev/null +++ b/actionfiles/build_and_push_docker_image/setup/install_skins.sh @@ -0,0 +1,10 @@ +#versions +tweeki_version=2.0.1 + + +if [ ! -d skins/Tweeki ]; then + echo "Downloading Tweeki skin" + wget https://github.com/thaider/Tweeki/archive/refs/tags/v${tweeki_version}.tar.gz + tar xf v${tweeki_version}.tar.gz + mv Tweeki-* skins/Tweeki +fi \ No newline at end of file